aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2013-07-02 03:20:44 +0800
committerMatthew Barnes <mbarnes@redhat.com>2013-07-02 22:34:12 +0800
commit23d786f06ad5c0a2827e22a129db7fbb1693b537 (patch)
tree62f844d8870a6306eb821d686bae50dbb09da239
parent7329de1078e5fbb71ab4dc7315f8f14b5956cc92 (diff)
downloadgsoc2013-evolution-23d786f06ad5c0a2827e22a129db7fbb1693b537.tar.gz
gsoc2013-evolution-23d786f06ad5c0a2827e22a129db7fbb1693b537.tar.zst
gsoc2013-evolution-23d786f06ad5c0a2827e22a129db7fbb1693b537.zip
e-mail-shell-view.c: Avoid e_tree_set_state().
Create our own ETableState and call e_table_state_load_from_string() followed by e_tree_set_state_object().
-rw-r--r--modules/mail/e-mail-shell-view.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/modules/mail/e-mail-shell-view.c b/modules/mail/e-mail-shell-view.c
index a5e5d62eaa..a4d5e9987c 100644
--- a/modules/mail/e-mail-shell-view.c
+++ b/modules/mail/e-mail-shell-view.c
@@ -201,8 +201,18 @@ mail_shell_view_show_search_results_folder (EMailShellView *mail_shell_view,
e_mail_reader_set_folder (reader, folder);
view_instance = e_mail_view_get_view_instance (mail_view);
- if (!view_instance || !gal_view_instance_exists (view_instance))
- e_tree_set_state (E_TREE (message_list), SEARCH_RESULTS_STATE);
+ if (!view_instance || !gal_view_instance_exists (view_instance)) {
+ ETree *tree;
+ ETableState *state;
+ ETableSpecification *specification;
+
+ tree = E_TREE (message_list);
+ specification = e_tree_get_spec (tree);
+ state = e_table_state_new (specification);
+ e_table_state_load_from_string (state, SEARCH_RESULTS_STATE);
+ e_tree_set_state_object (tree, state);
+ g_object_unref (state);
+ }
message_list_thaw (MESSAGE_LIST (message_list));
}