diff options
author | Rodrigo Moya <rodrigo@gnome-db.org> | 2011-11-14 20:08:57 +0800 |
---|---|---|
committer | Rodrigo Moya <rodrigo@gnome-db.org> | 2011-11-14 20:08:57 +0800 |
commit | 7ab5ae3fc72516cceeb09a48bc5a39f7b57933de (patch) | |
tree | f1d1afbfa9d8c97dc691a2d241c9ec368fdf67d3 /mail/mail-vfolder.c | |
parent | cda52538315c481bc3b11ff2db40f7165113d1ab (diff) | |
parent | c4308051159a37f16521b881f59259861998f4ae (diff) | |
download | gsoc2013-evolution-7ab5ae3fc72516cceeb09a48bc5a39f7b57933de.tar.gz gsoc2013-evolution-7ab5ae3fc72516cceeb09a48bc5a39f7b57933de.tar.zst gsoc2013-evolution-7ab5ae3fc72516cceeb09a48bc5a39f7b57933de.zip |
Merge branch 'master' into wip/gsettings
Diffstat (limited to 'mail/mail-vfolder.c')
-rw-r--r-- | mail/mail-vfolder.c | 62 |
1 files changed, 1 insertions, 61 deletions
diff --git a/mail/mail-vfolder.c b/mail/mail-vfolder.c index 5fe6c09d04..80d6f1ec0c 100644 --- a/mail/mail-vfolder.c +++ b/mail/mail-vfolder.c @@ -346,64 +346,6 @@ mv_find_folder (GQueue *queue, return link; } -static gint -uri_is_ignore (EMailBackend *backend, - const gchar *uri) -{ - EMailSession *session; - CamelSession *camel_session; - EAccountList *accounts; - EAccount *account; - EIterator *iter; - const gchar *local_drafts_uri; - const gchar *local_outbox_uri; - const gchar *local_sent_uri; - gint found = FALSE; - - local_drafts_uri = - e_mail_local_get_folder_uri (E_MAIL_LOCAL_FOLDER_DRAFTS); - local_outbox_uri = - e_mail_local_get_folder_uri (E_MAIL_LOCAL_FOLDER_OUTBOX); - local_sent_uri = - e_mail_local_get_folder_uri (E_MAIL_LOCAL_FOLDER_SENT); - - session = e_mail_backend_get_session (backend); - camel_session = CAMEL_SESSION (session); - - if (e_mail_folder_uri_equal (camel_session, local_outbox_uri, uri)) - return TRUE; - - if (e_mail_folder_uri_equal (camel_session, local_sent_uri, uri)) - return TRUE; - - if (e_mail_folder_uri_equal (camel_session, local_drafts_uri, uri)) - return TRUE; - - accounts = e_get_account_list (); - iter = e_list_get_iterator (E_LIST (accounts)); - - while (!found && e_iterator_is_valid (iter)) { - /* XXX EIterator misuses const. */ - account = (EAccount *) e_iterator_get (iter); - - if (!found && account->sent_folder_uri != NULL) - found = e_mail_folder_uri_equal ( - camel_session, uri, - account->sent_folder_uri); - - if (!found && account->drafts_folder_uri != NULL) - found = e_mail_folder_uri_equal ( - camel_session, uri, - account->drafts_folder_uri); - - e_iterator_next (iter); - } - - g_object_unref (iter); - - return found; -} - /* so special we never use it */ static gint folder_is_spethal (CamelStore *store, @@ -455,7 +397,7 @@ mail_vfolder_add_folder (EMailBackend *backend, GList *folders = NULL, *link; GQueue *queue; gint remote; - gint is_ignore; + gint is_ignore = FALSE; gchar *uri; session = e_mail_backend_get_session (backend); @@ -471,8 +413,6 @@ mail_vfolder_add_folder (EMailBackend *backend, uri = e_mail_folder_uri_build (store, folder_name); - is_ignore = uri_is_ignore (backend, uri); - G_LOCK (vfolder); /* maintain the source folders lists for changed rules later on */ |