g_return_if_fail(replyp!=NULL);
*replyp=reply;
+ gtk_main_quit();
}
void on_DruidButtonOK_clicked(GtkButton *button,gpointer user_data /* unused */)
gtk_main();
if (reply==0) /* 0 for 'OK', 1 for 'Cancel', left -1 for dialog close. */
exit(EXIT_SUCCESS);
- /* This does not work (at least not in the static build): gnome_dialog_set_close(,TRUE);
+ /* It is still needed despite: gnome_dialog_set_close(,TRUE);
* in: libgnomeui-2.10.0-1
+ * There may be some races regarding when is ran: gtk_main_quit();
*/
gtk_widget_destroy(dialog);
}
dialog=gnome_app_message(App,message);
gtk_window_set_modal(GTK_WINDOW(dialog),TRUE);
- /* It looks as if eariler libgnomeui had default TRUE
- * but since libgnomeui-2.10.0 it is FALSE, weird.
- */
+ /* See also around: gnome_dialog_set_close(); */
gnome_dialog_set_close(GNOME_DIALOG(dialog),FALSE);
- g_signal_connect((gpointer)dialog,"close",G_CALLBACK(gtk_main_quit),NULL);
+ g_signal_connect((gpointer)dialog,"close" ,G_CALLBACK(gtk_main_quit),NULL);
+ g_signal_connect((gpointer)dialog,"clicked",G_CALLBACK(gtk_main_quit),NULL);
gtk_main();
- /* This does not work (at least not in the static build): gnome_dialog_set_close(,TRUE);
- * in: libgnomeui-2.10.0-1
- */
+ /* See also around: gnome_dialog_set_close(); */
gtk_widget_destroy(dialog);
gdk_flush();