aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog5
-rw-r--r--mail/mail-callbacks.c33
2 files changed, 28 insertions, 10 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 670a739b5f..4341f962f8 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,8 @@
+2001-01-11 Miguel de Icaza <miguel@gnu.org>
+
+ * mail-callbacks.c (configure_mail): Force finalization of the
+ function before returning fixing the FIXME that was there.
+
2001-01-11 Jeffrey Stedfast <fejj@helixcode.com>
* mail-config-druid.c (transport_next): If the service_check
diff --git a/mail/mail-callbacks.c b/mail/mail-callbacks.c
index 7943e27443..b691fbe591 100644
--- a/mail/mail-callbacks.c
+++ b/mail/mail-callbacks.c
@@ -65,6 +65,12 @@ struct post_send_data {
};
static void
+druid_destroyed (void)
+{
+ gtk_main_quit ();
+}
+
+static void
configure_mail (FolderBrowser *fb)
{
MailConfigDruid *druid;
@@ -72,21 +78,28 @@ configure_mail (FolderBrowser *fb)
if (fb) {
GtkWidget *dialog;
- dialog = gnome_message_box_new (_("You have not configured the mail client.\n"
- "You need to do this before you can send,\n"
- "receive or compose mail.\n"
- "Would you like to configure it now?"),
- GNOME_MESSAGE_BOX_QUESTION,
- GNOME_STOCK_BUTTON_YES,
- GNOME_STOCK_BUTTON_NO, NULL);
- gnome_dialog_set_parent (GNOME_DIALOG (dialog),
- GTK_WINDOW (gtk_widget_get_ancestor (GTK_WIDGET (fb), GTK_TYPE_WINDOW)));
+ dialog = gnome_message_box_new (
+ _("You have not configured the mail client.\n"
+ "You need to do this before you can send,\n"
+ "receive or compose mail.\n"
+ "Would you like to configure it now?"),
+ GNOME_MESSAGE_BOX_QUESTION,
+ GNOME_STOCK_BUTTON_YES,
+ GNOME_STOCK_BUTTON_NO, NULL);
+
+ gnome_dialog_set_parent (
+ GNOME_DIALOG (dialog),
+ GTK_WINDOW (gtk_widget_get_ancestor (
+ GTK_WIDGET (fb), GTK_TYPE_WINDOW)));
switch (gnome_dialog_run_and_close (GNOME_DIALOG (dialog))) {
case 0:
- /* FIXME: should we block until mail-config is done? */
druid = mail_config_druid_new (fb->shell);
+ gtk_signal_connect (GTK_OBJECT (druid), "destroy",
+ GTK_SIGNAL_FUNC (druid_destroyed), NULL);
gtk_widget_show (GTK_WIDGET (druid));
+ gtk_grab_add (GTK_WIDGET (druid));
+ gtk_main ();
break;
case 1:
default: