raster pushed a commit to branch master.
commit ea2956b28f14394bb41ee0efc95ce6dd53d35002
Author: Carsten Haitzler (Rasterman) <[email protected]>
Date: Mon Apr 15 13:52:47 2013 +0900
cover delayed delete being for already deleted panel from other window.
---
src/bin/controls.c | 23 +++++++++++++++++++++--
1 file changed, 21 insertions(+), 2 deletions(-)
diff --git a/src/bin/controls.c b/src/bin/controls.c
index f016dbb..732db09 100644
--- a/src/bin/controls.c
+++ b/src/bin/controls.c
@@ -23,8 +23,11 @@ _cb_ct_del_delay(void *data __UNUSED__)
evas_object_del(ct_over);
ct_over = NULL;
}
- evas_object_del(ct_frame);
- ct_frame = NULL;
+ if (ct_frame)
+ {
+ evas_object_del(ct_frame);
+ ct_frame = NULL;
+ }
ct_del_timer = NULL;
elm_cache_all_flush();
return EINA_FALSE;
@@ -89,6 +92,18 @@ _cb_mouse_down(void *data __UNUSED__, Evas *e __UNUSED__,
Evas_Object *obj __UNU
}
static void
+_cb_frame_del(void *data __UNUSED__, Evas *e __UNUSED__, Evas_Object *obj
__UNUSED__, void *ev __UNUSED__)
+{
+ ct_frame = NULL;
+}
+
+static void
+_cb_over_del(void *data __UNUSED__, Evas *e __UNUSED__, Evas_Object *obj
__UNUSED__, void *ev __UNUSED__)
+{
+ ct_over = NULL;
+}
+
+static void
_cb_saved_del(void *data __UNUSED__, Evas *e __UNUSED__, Evas_Object *obj
__UNUSED__, void *ev __UNUSED__)
{
if ((obj == ct_win) || (obj == ct_term))
@@ -227,6 +242,8 @@ controls_toggle(Evas_Object *win, Evas_Object *bg,
Evas_Object *term,
o = _button_add(win, "About", "about", _cb_ct_about, term);
elm_box_pack_end(ct_box, o);
+ evas_object_event_callback_add(ct_frame, EVAS_CALLBACK_DEL,
+ _cb_frame_del, NULL);
}
if (!ct_out)
{
@@ -238,6 +255,8 @@ controls_toggle(Evas_Object *win, Evas_Object *bg,
Evas_Object *term,
evas_object_show(o);
evas_object_event_callback_add(o, EVAS_CALLBACK_MOUSE_DOWN,
_cb_mouse_down, term);
+ evas_object_event_callback_add(ct_over, EVAS_CALLBACK_DEL,
+ _cb_over_del, NULL);
ct_win = win;
ct_bg = bg;
--
------------------------------------------------------------------------------
Precog is a next-generation analytics platform capable of advanced
analytics on semi-structured data. The platform includes APIs for building
apps and a phenomenal toolset for data science. Developers can use
our toolset for easy data analysis & visualization. Get a free account!
http://www2.precog.com/precogplatform/slashdotnewsletter