aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Blumenkrantz <m.blumenkran@samsung.com>2013-02-21 12:51:59 +0000
committerMike Blumenkrantz <m.blumenkran@samsung.com>2013-02-22 13:18:30 +0000
commit19f79acb454fa259ddfbb2024bb68e07fd873749 (patch)
treeaa658cee07a8db61994150fce2b122a32410774c
parent7128c8fbe68de9365dc9da987911beb65ab4af07 (diff)
downloadenlightenment-19f79acb454fa259ddfbb2024bb68e07fd873749.tar.gz
enlightenment-19f79acb454fa259ddfbb2024bb68e07fd873749.tar.xz
enlightenment-19f79acb454fa259ddfbb2024bb68e07fd873749.zip
add e_gadcon_repopulate
this allows unpopulate+repopulate calls to occur while the layout is frozen, providing a substantial speedup
-rw-r--r--ChangeLog1
-rw-r--r--NEWS1
-rw-r--r--src/bin/e_gadcon.c11
-rw-r--r--src/bin/e_gadcon.h1
4 files changed, 14 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index c54ad2839..e379e114c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,7 @@
* added E_LIST_REVERSE_FREE macro
* added e_object_ref_debug_set
* E_FN_DEL macro renamed to E_FREE_FUNC with param order swapped for consistency
+ * added e_gadcon_repopulate
2013-02-20 Mike Blumenkrantz
diff --git a/NEWS b/NEWS
index 824ee8c0b..2a98f75a0 100644
--- a/NEWS
+++ b/NEWS
@@ -32,6 +32,7 @@ Additions:
* added functions for noting objects which are part of a popup
* added E_LIST_REVERSE_FREE macro
* added e_object_ref_debug_set
+ * added e_gadcon_repopulate
Config:
* Added option for disabling icons in menus
* Added option for disabling pointer warping when performing directional focus changes using winlist
diff --git a/src/bin/e_gadcon.c b/src/bin/e_gadcon.c
index 90fec35c3..abb80496b 100644
--- a/src/bin/e_gadcon.c
+++ b/src/bin/e_gadcon.c
@@ -615,6 +615,17 @@ e_gadcon_unpopulate(E_Gadcon *gc)
}
EAPI void
+e_gadcon_repopulate(E_Gadcon *gc)
+{
+ E_OBJECT_CHECK(gc);
+ E_OBJECT_TYPE_CHECK(gc, E_GADCON_TYPE);
+ if (gc->o_container) e_gadcon_layout_freeze(gc->o_container);
+ e_gadcon_unpopulate(gc);
+ e_gadcon_populate(gc);
+ if (gc->o_container) e_gadcon_layout_thaw(gc->o_container);
+}
+
+EAPI void
e_gadcon_populate_class(E_Gadcon *gc, const E_Gadcon_Client_Class *cc)
{
Eina_List *l;
diff --git a/src/bin/e_gadcon.h b/src/bin/e_gadcon.h
index 960274aa9..8fd492739 100644
--- a/src/bin/e_gadcon.h
+++ b/src/bin/e_gadcon.h
@@ -292,6 +292,7 @@ EAPI void e_gadcon_populate_callback_set(E_Gadcon *gc, void (
EAPI void e_gadcon_layout_policy_set(E_Gadcon *gc, E_Gadcon_Layout_Policy layout_policy);
EAPI Eina_Bool e_gadcon_populate(E_Gadcon *gc);
EAPI void e_gadcon_unpopulate(E_Gadcon *gc);
+EAPI void e_gadcon_repopulate(E_Gadcon *gc);
EAPI void e_gadcon_populate_class(E_Gadcon *gc, const E_Gadcon_Client_Class *cc);
EAPI void e_gadcon_orient(E_Gadcon *gc, E_Gadcon_Orient orient);
EAPI void e_gadcon_edit_begin(E_Gadcon *gc);