bu5hm4n pushed a commit to branch master. http://git.enlightenment.org/apps/extra.git/commit/?id=4030ddba2fc9d0a321727c9cdc641edce5037b32
commit 4030ddba2fc9d0a321727c9cdc641edce5037b32 Author: Marcel Hollerbach <marcel-hollerb...@t-online.de> Date: Mon Jan 23 22:54:12 2017 +0100 extra: remove popup toolbar when details are opened --- src/bin/extra_theme_selector.c | 3 ++- src/bin/extra_util.c | 15 +++++++++++---- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/src/bin/extra_theme_selector.c b/src/bin/extra_theme_selector.c index 64616c3..4101639 100644 --- a/src/bin/extra_theme_selector.c +++ b/src/bin/extra_theme_selector.c @@ -197,6 +197,7 @@ static void _show_details(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED) { _popup_theme(_ui.win, data); + evas_object_del(_ui.popup_toolbar); } static void @@ -333,4 +334,4 @@ extra_theme_small_new(Evas_Object *par, Extra_Theme *theme) counter ++; } return table; -} \ No newline at end of file +} diff --git a/src/bin/extra_util.c b/src/bin/extra_util.c index 6153ebc..ce7827f 100644 --- a/src/bin/extra_util.c +++ b/src/bin/extra_util.c @@ -246,9 +246,14 @@ extra_ui_fullscreen_preview(char *path) } static void -_popup_del_cb(void *data, Evas *e EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED) +_popup_block_click_cb(void *data EINA_UNUSED, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED) +{ + elm_popup_dismiss(_ui.popup_toolbar); +} + +static void +_popup_del_cb(void *data EINA_UNUSED, Evas *e EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED) { - elm_popup_dismiss(data); evas_object_del(obj); _ui.popup_toolbar = NULL; } @@ -275,9 +280,11 @@ extra_ui_show_popup_toolbar(Evas_Object *content) evas_object_size_hint_weight_set(rect, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); evas_object_size_hint_align_set(rect, EVAS_HINT_FILL, EVAS_HINT_FILL); evas_object_color_set(rect, 0, 0, 0, 0); - evas_object_event_callback_add(rect, EVAS_CALLBACK_MOUSE_DOWN, _popup_del_cb, tooltip); + evas_object_event_callback_add(rect, EVAS_CALLBACK_MOUSE_DOWN, _popup_block_click_cb, tooltip); elm_win_resize_object_add(_ui.win, rect); evas_object_show(rect); + evas_object_event_callback_add(tooltip, EVAS_CALLBACK_DEL, _popup_del_cb, rect); + _ui.popup_toolbar = tooltip; -} \ No newline at end of file +} --