diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2011-12-07 23:57:35 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@redhat.com> | 2011-12-07 23:57:35 +0800 |
commit | 194ab4aebcca2958d1d9f794086fa997310a6c07 (patch) | |
tree | f48e2c30764b138bac4c5b4588bd052e424227f1 | |
parent | f278751c734c51cb7acfd6f312afb25fca11b57f (diff) | |
download | gsoc2013-evolution-194ab4aebcca2958d1d9f794086fa997310a6c07.tar.gz gsoc2013-evolution-194ab4aebcca2958d1d9f794086fa997310a6c07.tar.zst gsoc2013-evolution-194ab4aebcca2958d1d9f794086fa997310a6c07.zip |
EMFolderTreeModel: Check for vfolder store by its UID.
-rw-r--r-- | mail/em-folder-tree-model.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/mail/em-folder-tree-model.c b/mail/em-folder-tree-model.c index e63d36261f..27fa44aea4 100644 --- a/mail/em-folder-tree-model.c +++ b/mail/em-folder-tree-model.c @@ -93,8 +93,6 @@ enum { LAST_SIGNAL }; -extern CamelStore *vfolder_store; - static gpointer parent_class; static guint signals[LAST_SIGNAL]; @@ -129,6 +127,7 @@ folder_tree_model_sort (GtkTreeModel *model, gchar *aname, *bname; CamelStore *store; gboolean is_store; + const gchar *store_uid = NULL; guint32 aflags, bflags; guint asortorder, bsortorder; gint rv = -2; @@ -153,6 +152,9 @@ folder_tree_model_sort (GtkTreeModel *model, COL_UINT_SORTORDER, &bsortorder, -1); + if (CAMEL_IS_SERVICE (store)) + store_uid = camel_service_get_uid (CAMEL_SERVICE (store)); + if (is_store) { EShell *shell; EShellBackend *shell_backend; @@ -202,7 +204,7 @@ folder_tree_model_sort (GtkTreeModel *model, else rv = 0; } - } else if (store == vfolder_store) { + } else if (g_strcmp0 (store_uid, "vfolder") == 0) { /* UNMATCHED is always last. */ if (aname && !strcmp (aname, _("UNMATCHED"))) rv = 1; |