aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog10
-rw-r--r--mail/mail-callbacks.c27
2 files changed, 28 insertions, 9 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 3b2ac73b54..c0703762d8 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,5 +1,15 @@
2001-10-04 Jeffrey Stedfast <fejj@ximian.com>
+ * mail-callbacks.c (providers_config): Set the parent window as
+ the fb. This fixes bug #11723.
+ (filter_edit): Do the same thing here too and also to the warning
+ dialog.
+ (edit_msg): Set the parent on the warning dialog.
+ (resend_msg): And here.
+ (search_msg): Here too.
+ (confirm_expunge): Set the parent window on the dialog here too.
+ (save_msg_ok): Same here.
+
* mail-accounts.c (images_radio_toggled): Ignore the signal if the
radio button is not "on". This fixes bug #10532 because the on/off
signals don't always come in the off->on order.
diff --git a/mail/mail-callbacks.c b/mail/mail-callbacks.c
index 11e4aec473..8fba1b50d8 100644
--- a/mail/mail-callbacks.c
+++ b/mail/mail-callbacks.c
@@ -1566,8 +1566,9 @@ edit_msg (GtkWidget *widget, gpointer user_data)
if (!folder_browser_is_drafts (fb)) {
GtkWidget *message;
- message = gnome_warning_dialog (_("You may only edit messages saved\n"
- "in the Drafts folder."));
+ message = gnome_warning_dialog_parented (_("You may only edit messages saved\n"
+ "in the Drafts folder."),
+ GTK_WINDOW (fb));
gnome_dialog_run_and_close (GNOME_DIALOG (message));
return;
}
@@ -1600,8 +1601,9 @@ resend_msg (GtkWidget *widget, gpointer user_data)
if (!folder_browser_is_sent (fb)) {
GtkWidget *message;
- message = gnome_warning_dialog (_("You may only resend messages\n"
- "in the Sent folder."));
+ message = gnome_warning_dialog_parented (_("You may only resend messages\n"
+ "in the Sent folder."),
+ GTK_WINDOW (fb));
gnome_dialog_run_and_close (GNOME_DIALOG (message));
return;
}
@@ -1633,7 +1635,7 @@ search_msg (GtkWidget *widget, gpointer user_data)
GtkWidget *w;
if (fb->mail_display->current_message == NULL) {
- gtk_widget_show_all (gnome_warning_dialog (_("No Message Selected")));
+ gtk_widget_show_all (gnome_warning_dialog_parented (_("No Message Selected"), GTK_WINDOW (fb)));
return;
}
@@ -1673,6 +1675,8 @@ save_msg_ok (GtkWidget *widget, gpointer user_data)
GNOME_STOCK_BUTTON_NO,
NULL);
+ gnome_dialog_set_parent (GNOME_DIALOG (dialog), GTK_WINDOW (user_data));
+
gtk_widget_set_parent (dialog, GTK_WIDGET (user_data));
text = gtk_label_new (_("A file by that name already exists.\nOverwrite it?"));
gtk_box_pack_start (GTK_BOX (GNOME_DIALOG (dialog)->vbox), text, TRUE, TRUE, 4);
@@ -1857,7 +1861,7 @@ expunged_folder (CamelFolder *f, void *data)
}
static gboolean
-confirm_expunge (void)
+confirm_expunge (FolderBrowser *fb)
{
GtkWidget *dialog, *label, *checkbox;
int button;
@@ -1870,6 +1874,8 @@ confirm_expunge (void)
GNOME_STOCK_BUTTON_NO,
NULL);
+ gnome_dialog_set_parent (GNOME_DIALOG (dialog), GTK_WINDOW (fb));
+
label = gtk_label_new (_("This operation will permanently erase all messages marked as deleted. If you continue, you will not be able to recover these messages.\n\nReally erase these messages?"));
gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
@@ -1900,7 +1906,7 @@ expunge_folder (BonoboUIComponent *uih, void *user_data, const char *path)
{
FolderBrowser *fb = FOLDER_BROWSER (user_data);
- if (fb->folder && (fb->expunging == NULL || fb->folder != fb->expunging) && confirm_expunge ()) {
+ if (fb->folder && (fb->expunging == NULL || fb->folder != fb->expunging) && confirm_expunge (fb)) {
struct _expunged_folder_data *data;
CamelMessageInfo *info;
@@ -1984,7 +1990,7 @@ filter_edit (BonoboUIComponent *uih, void *user_data, const char *path)
err = g_strdup_printf (_("Error loading filter information:\n%s"),
((RuleContext *)fc)->error);
- dialog = gnome_warning_dialog (err);
+ dialog = gnome_warning_dialog_parented (err, GTK_WINDOW (fb));
g_free (err);
gnome_dialog_run_and_close (GNOME_DIALOG (dialog));
@@ -1992,6 +1998,7 @@ filter_edit (BonoboUIComponent *uih, void *user_data, const char *path)
}
filter_editor = (GtkWidget *)filter_editor_new (fc, filter_source_names);
+ gnome_dialog_set_parent (GNOME_DIALOG (filter_editor), GTK_WINDOW (fb));
gtk_window_set_title (GTK_WINDOW (filter_editor), _("Filters"));
gtk_object_set_data_full (GTK_OBJECT (filter_editor), "context", fc, (GtkDestroyNotify)gtk_object_unref);
@@ -2012,9 +2019,11 @@ void
providers_config (BonoboUIComponent *uih, void *user_data, const char *path)
{
static MailAccountsDialog *dialog = NULL;
+ FolderBrowser *fb = user_data;
if (!dialog) {
- dialog = mail_accounts_dialog_new ((FOLDER_BROWSER (user_data))->shell);
+ dialog = mail_accounts_dialog_new (fb->shell);
+ gnome_dialog_set_parent (GNOME_DIALOG (dialog), GTK_WINDOW (fb));
gnome_dialog_run_and_close (GNOME_DIALOG (dialog));
dialog = NULL;
} else {