70 if (this_proj -> modelgl)
72 if ((this_proj -> modelgl -> atom_win && this_proj -> modelgl -> atom_win -> visible) || this_proj -> modelgl ->
builder_win)
75 box = (this_proj -> modelgl ->
builder_win) ? this_proj -> modelgl ->
builder_win -> add_combo : this_proj -> modelgl -> atom_win -> atom_combo[3];
76 gtk_combo_box_set_model (GTK_COMBO_BOX(box),
model);
77 gtk_combo_box_set_active (GTK_COMBO_BOX(box), 0);
78 cell_list = gtk_cell_layout_get_cells(GTK_CELL_LAYOUT(box));
79 if (cell_list && cell_list -> data)
81 gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(box), cell_list -> data,
"markup", 0, NULL);
83 g_object_unref (
model);
101 g_debug (
"CLOSE_PROJECT: proj to close= %d", to_close ->
id);
102 g_debug (
"CLOSE_PROJECT: nprojects = %d",
nprojects);
103 g_debug (
"CLOSE_PROJECT: activep = %d",
activep);
106 if (to_close -> initgl)
108 if (to_close -> modelgl -> measure_win)
110 to_close -> modelgl -> measure_win -> win =
destroy_this_widget (to_close -> modelgl -> measure_win -> win);
111 g_free (to_close -> modelgl -> measure_win);
113 if (to_close -> modelgl -> volume_win)
115 to_close -> modelgl -> volume_win -> win =
destroy_this_widget (to_close -> modelgl -> volume_win -> win);
116 g_free (to_close -> modelgl -> volume_win);
118 if (to_close -> modelgl -> player)
120 to_close -> modelgl -> player -> win =
destroy_this_widget (to_close -> modelgl -> player -> win);
121 g_free (to_close -> modelgl -> player);
123 if (to_close -> modelgl -> spiner)
125 to_close -> modelgl -> spiner -> win =
destroy_this_widget (to_close -> modelgl -> spiner -> win);
126 g_free (to_close -> modelgl -> spiner);
128 if (to_close -> modelgl -> rec)
130 to_close -> modelgl -> rec -> win =
destroy_this_widget (to_close -> modelgl -> rec -> win);
131 g_free (to_close -> modelgl -> rec);
133 if (to_close -> modelgl -> atom_win)
135 to_close -> modelgl -> atom_win -> win =
destroy_this_widget (to_close -> modelgl -> atom_win -> win);
136 g_free (to_close -> modelgl -> atom_win);
138 if (to_close -> modelgl -> cell_win)
140 to_close -> modelgl -> cell_win -> win =
destroy_this_widget (to_close -> modelgl -> cell_win -> win);
141 g_free (to_close -> modelgl -> cell_win);
148 if (to_close -> modelgl -> coord_win)
150 to_close -> modelgl -> coord_win -> win =
destroy_this_widget (to_close -> modelgl -> coord_win -> win);
151 g_free (to_close -> modelgl -> coord_win);
155 if (to_close -> modelgl -> model_win[i])
157 to_close -> modelgl -> model_win[i] -> win =
destroy_this_widget (to_close -> modelgl -> model_win[i] -> win);
158 g_free (to_close -> modelgl -> model_win[i]);
161 if (to_close -> modelgl -> opengl_win)
163 to_close -> modelgl -> opengl_win -> win =
destroy_this_widget (to_close -> modelgl -> opengl_win -> win);
164 g_free (to_close -> modelgl -> opengl_win);
168 g_free (to_close -> modelgl);
169 if (to_close -> modelfc)
171 for (i=0; i< to_close -> steps; i++)
173 g_free (to_close -> modelfc -> mols[i]);
181 to_close -> visok[i]=FALSE;
182 if (to_close -> curves[i])
219 to_close -> prev -> next = to_close -> next;
220 to_close -> next -> prev = to_close -> prev;
231 if (this_proj -> initgl)
233 this_proj -> modelgl ->
proj = i;
236 for (k=0; k<this_proj -> nspec*2; k++)
238 this_proj -> modelgl ->
colorp[j][k].a = i;
243 if (this_proj -> modelgl -> gcid[j] != NULL)
245 for (k=0; k<this_proj -> coord -> totcoord[j]; k++)
249 this_proj -> modelgl -> gcid[j][k][l].a = i;
254 if (this_proj -> modelgl -> atom_win)
258 if (this_proj -> modelgl -> search_widg[j])
260 for (k=0; k<3; k++) this_proj -> modelgl -> search_widg[j] -> pointer[k].
a = i;
267 if (this_proj -> idcc[j] != NULL)
269 for (k=0; k<this_proj -> numc[j]; k++)
271 this_proj -> idcc[j][k].a = i;
275 if (this_proj -> next != NULL) this_proj = this_proj -> next;
283 for (k=0; k<this_proj -> numc[j]; k++)
285 if (this_proj -> curves[j][k] -> window)
290 gtk_widget_queue_draw (this_proj -> curves[j][k] ->
plot);
295 if (this_proj -> next != NULL) this_proj = this_proj -> next;