summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hollerbach <marcel@osg.samsung.com>2017-12-04 20:40:38 +0000
committerMarcel Hollerbach <marcel@osg.samsung.com>2017-12-04 20:40:38 +0000
commitca0f10f40dd63269487fab4793f5c176fa62bf09 (patch)
tree2e7b0d490aa3314c1d0cf73ee19e495f57980a50
parentd3216f23e87afdb10fda106fefdc1ecb30669e3b (diff)
wiked: remove popup if there is a new one
-rw-r--r--src/main.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/main.c b/src/main.c
index a478dc3..b90b246 100644
--- a/src/main.c
+++ b/src/main.c
@@ -2,7 +2,7 @@
2#include <Ecore_Con.h> 2#include <Ecore_Con.h>
3#include <Elementary.h> 3#include <Elementary.h>
4 4
5static Evas_Object *win; 5static Evas_Object *win, *popup;
6static Ecore_Timer *timer = NULL; 6static Ecore_Timer *timer = NULL;
7static Wiki *w; 7static Wiki *w;
8 8
@@ -15,7 +15,10 @@ _wiki_item_clicked_twice(void *data EINA_UNUSED, Evas_Object *obj, void *event_i
15static Eina_Value 15static Eina_Value
16_wiki_arrived(void *data, const Eina_Value value, const Eina_Future *f) 16_wiki_arrived(void *data, const Eina_Value value, const Eina_Future *f)
17{ 17{
18 Evas_Object *popup, *entry = data, *list; 18 Evas_Object *entry = data, *list;
19
20 if (popup)
21 evas_object_del(popup);
19 22
20 //this creates a new popup due to runner 23 //this creates a new popup due to runner
21 popup = elm_win_add(elm_win_get(entry), "win", ELM_WIN_POPUP_MENU); 24 popup = elm_win_add(elm_win_get(entry), "win", ELM_WIN_POPUP_MENU);