aboutsummaryrefslogtreecommitdiffstats
path: root/my-evolution/e-summary-shown.c
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2003-03-13 01:27:11 +0800
committerDan Winship <danw@src.gnome.org>2003-03-13 01:27:11 +0800
commitffec3e92a36ce871a71c5e739fbaf08fa957ab9c (patch)
tree26f579377605c5d00d59cc442fca898d54d07f0f /my-evolution/e-summary-shown.c
parentc32307b1c859b5b763ec33ca1e2ad54727ce1608 (diff)
downloadgsoc2013-evolution-ffec3e92a36ce871a71c5e739fbaf08fa957ab9c.tar.gz
gsoc2013-evolution-ffec3e92a36ce871a71c5e739fbaf08fa957ab9c.tar.zst
gsoc2013-evolution-ffec3e92a36ce871a71c5e739fbaf08fa957ab9c.zip
New, to free/thaw the ETree models. (e_summary_shown_add_node): Don't
* e-summary-shown.c (e_summary_shown_freeze, e_summary_shown_thaw): New, to free/thaw the ETree models. (e_summary_shown_add_node): Don't freeze/thaw around the single add here. That doesn't really help much. * e-summary-preferences.c (fill_rdf_etable): Freeze/thaw the ESummaryShown while filling it in. * e-summary-weather.c (e_summary_weather_fill_etable): Likewise. svn path=/trunk/; revision=20263
Diffstat (limited to 'my-evolution/e-summary-shown.c')
-rw-r--r--my-evolution/e-summary-shown.c36
1 files changed, 19 insertions, 17 deletions
diff --git a/my-evolution/e-summary-shown.c b/my-evolution/e-summary-shown.c
index b8f2b4bd80..98301059c1 100644
--- a/my-evolution/e-summary-shown.c
+++ b/my-evolution/e-summary-shown.c
@@ -558,22 +558,6 @@ e_summary_shown_new (void)
return GTK_WIDGET (shown);
}
-static ETreePath
-e_tree_model_node_append (ETreeModel *etm,
- ETreePath parent,
- gpointer data)
-{
- ETreeMemory *etmm;
- ETreePath path;
-
- etmm = E_TREE_MEMORY (etm);
- e_tree_memory_freeze (etmm);
- path = e_tree_memory_node_insert (etmm, parent, -1, data);
- e_tree_memory_thaw (etmm);
-
- return path;
-}
-
ETreePath
e_summary_shown_add_node (ESummaryShown *shown,
gboolean all,
@@ -603,7 +587,7 @@ e_summary_shown_add_node (ESummaryShown *shown,
}
etmm = E_TREE_MEMORY (td->etm);
- path = e_tree_model_node_append (td->etm, parent, data);
+ path = e_tree_memory_node_insert (etmm, parent, -1, data);
tree = e_tree_scrolled_get_tree (E_TREE_SCROLLED (td->etable));
e_tree_node_set_expanded (tree, path, expanded);
@@ -650,6 +634,24 @@ e_summary_shown_remove_node (ESummaryShown *shown,
}
+void
+e_summary_shown_freeze (ESummaryShown *shown)
+{
+ g_return_if_fail (IS_E_SUMMARY_SHOWN (shown));
+
+ e_tree_memory_freeze (E_TREE_MEMORY (shown->priv->all->etm));
+ e_tree_memory_freeze (E_TREE_MEMORY (shown->priv->shown->etm));
+}
+
+void
+e_summary_shown_thaw (ESummaryShown *shown)
+{
+ g_return_if_fail (IS_E_SUMMARY_SHOWN (shown));
+
+ e_tree_memory_thaw (E_TREE_MEMORY (shown->priv->all->etm));
+ e_tree_memory_thaw (E_TREE_MEMORY (shown->priv->shown->etm));
+}
+
static void
make_list (ETreePath path,
gpointer data)