aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-folder-tree.c
diff options
context:
space:
mode:
authorNot Zed <NotZed@Ximian.com>2004-05-21 17:10:00 +0800
committerMichael Zucci <zucchi@src.gnome.org>2004-05-21 17:10:00 +0800
commitffa75e6801faaffb2626d83779fe0a91a8f58d3a (patch)
treede74dcb1ab7ea1e4dc93d9421215bb02a2c05f99 /mail/em-folder-tree.c
parent2bc97c08c1ca8057f03b3b3d872eafa306bab22c (diff)
downloadgsoc2013-evolution-ffa75e6801faaffb2626d83779fe0a91a8f58d3a.tar.gz
gsoc2013-evolution-ffa75e6801faaffb2626d83779fe0a91a8f58d3a.tar.zst
gsoc2013-evolution-ffa75e6801faaffb2626d83779fe0a91a8f58d3a.zip
add marshaller for p_ppppp call.
2004-05-21 Not Zed <NotZed@Ximian.com> * mail-mt.c (do_call): add marshaller for p_ppppp call. * mail-session.c (get_password): fix for camel api changes. (forget_password): same. ** See #58376. * message-list.c (mail_regen_list): do some timeout foo so we don't keep doing list regnerations if we're getting called too often. God knows what this will break. (message_list_set_selected): removede bug printf. (regen_list_free): move the message-list poking stuff into regen_list_regened. (message_list_set_folder): call mail_regen_cancel to cancel any regen stuff. (mail_regen_cancel): cancel/clear outstanding regenerations. (message_list_destroy): do it here too. (message_list_select_uid): also set the pending select uid if we have a timeout pending. * mail-component.c (impl_createControls): set the defualt parent to the main folderview as soon as its created. * em-folder-tree.c (emft_popup_copy_folder_selected): use get_toplevel rather than get_ancestor. seems the more reliable one. also we're always parented so we shoudl always find a toplevel window. (em_folder_tree_create_folder): same. (emft_popup_delete_response): set error parent. (emft_popup_delete_folder, emft_popup_rename_folder) (emft_popup_rename_folder, emft_popup_rename_folder): svn path=/trunk/; revision=26030
Diffstat (limited to 'mail/em-folder-tree.c')
-rw-r--r--mail/em-folder-tree.c23
1 files changed, 14 insertions, 9 deletions
diff --git a/mail/em-folder-tree.c b/mail/em-folder-tree.c
index e789f5e233..67e16ae0bf 100644
--- a/mail/em-folder-tree.c
+++ b/mail/em-folder-tree.c
@@ -2007,19 +2007,19 @@ emft_popup_copy_folder_selected (const char *uri, void *data)
frombase = priv->selected_path + 1;
if (!(fromstore = camel_session_get_store (session, priv->selected_uri, &ex))) {
- e_error_run((GtkWindow *)gtk_widget_get_ancestor ((GtkWidget *) cfd->emft, GTK_TYPE_WINDOW),
+ e_error_run((GtkWindow *)gtk_widget_get_toplevel((GtkWidget *) cfd->emft),
cfd->delete?"mail:no-move-folder-notexist":"mail:no-copy-folder-notexist", frombase, uri, ex.desc, NULL);
goto fail;
}
if (cfd->delete && fromstore == mail_component_peek_local_store (NULL) && is_special_local_folder (frombase)) {
- e_error_run((GtkWindow *)gtk_widget_get_ancestor ((GtkWidget *) cfd->emft, GTK_TYPE_WINDOW),
+ e_error_run((GtkWindow *)gtk_widget_get_toplevel((GtkWidget *) cfd->emft),
"mail:no-rename-special-folder", frombase, NULL);
goto fail;
}
if (!(tostore = camel_session_get_store (session, uri, &ex))) {
- e_error_run((GtkWindow *)gtk_widget_get_ancestor ((GtkWidget *) cfd->emft, GTK_TYPE_WINDOW),
+ e_error_run((GtkWindow *)gtk_widget_get_toplevel((GtkWidget *) cfd->emft),
cfd->delete?"mail:no-move-folder-to-notexist":"mail:no-move-folder-to-notexist", frombase, uri, ex.desc, NULL);
goto fail;
}
@@ -2194,7 +2194,7 @@ em_folder_tree_create_folder (EMFolderTree *emft, const char *path, const char *
camel_exception_init (&ex);
if (!(store = (CamelStore *) camel_session_get_service (session, uri, CAMEL_PROVIDER_STORE, &ex))) {
- e_error_run((GtkWindow *)gtk_widget_get_ancestor((GtkWidget *)emft, GTK_TYPE_WINDOW),
+ e_error_run((GtkWindow *)gtk_widget_get_toplevel((GtkWidget *)emft),
"mail:no-create-folder-nostore", path, ex.desc, NULL);
goto fail;
}
@@ -2398,7 +2398,8 @@ emft_popup_delete_response (GtkWidget *dialog, guint response, EMFolderTree *emf
camel_exception_init (&ex);
emft_popup_delete_folders (store, path, &ex);
if (camel_exception_is_set (&ex)) {
- e_error_run(NULL, "mail:no-delete-folder", path, ex.desc, NULL);
+ e_error_run((GtkWindow *)gtk_widget_get_toplevel((GtkWidget *)emft),
+ "mail:no-delete-folder", path, ex.desc, NULL);
camel_exception_clear (&ex);
}
}
@@ -2429,7 +2430,8 @@ emft_popup_delete_folder (GtkWidget *item, EMFolderTree *emft)
return;
}
- dialog = e_error_new(NULL, "mail:ask-delete-folder", full_name, NULL);
+ dialog = e_error_new((GtkWindow *)gtk_widget_get_toplevel((GtkWidget *)emft),
+ "mail:ask-delete-folder", full_name, NULL);
g_signal_connect (dialog, "response", G_CALLBACK (emft_popup_delete_response), emft);
gtk_widget_show (dialog);
}
@@ -2462,7 +2464,8 @@ emft_popup_rename_folder (GtkWidget *item, EMFolderTree *emft)
/* don't allow user to rename one of the special local folders */
if (store == local && is_special_local_folder (full_name)) {
- e_error_run(NULL, "mail:no-rename-spethal-folder", full_name, NULL);
+ e_error_run((GtkWindow *)gtk_widget_get_toplevel((GtkWidget *)emft),
+ "mail:no-rename-spethal-folder", full_name, NULL);
return;
}
@@ -2495,7 +2498,8 @@ emft_popup_rename_folder (GtkWidget *item, EMFolderTree *emft)
camel_exception_init (&ex);
if ((fi = camel_store_get_folder_info (store, path, CAMEL_STORE_FOLDER_INFO_FAST, &ex)) != NULL) {
camel_store_free_folder_info (store, fi);
- e_error_run(NULL, "mail:no-rename-folder-exists", name, new_name, NULL);
+ e_error_run((GtkWindow *)gtk_widget_get_toplevel((GtkWidget *)emft),
+ "mail:no-rename-folder-exists", name, new_name, NULL);
} else {
const char *oldpath, *newpath;
@@ -2507,7 +2511,8 @@ emft_popup_rename_folder (GtkWidget *item, EMFolderTree *emft)
camel_exception_clear (&ex);
camel_store_rename_folder (store, oldpath, newpath, &ex);
if (camel_exception_is_set (&ex)) {
- e_error_run(NULL, "mail:no-rename-folder", oldpath, newpath, ex.desc, NULL);
+ e_error_run((GtkWindow *)gtk_widget_get_toplevel((GtkWidget *)emft),
+ "mail:no-rename-folder", oldpath, newpath, ex.desc, NULL);
camel_exception_clear (&ex);
}