aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/extantz/winFang.c
diff options
context:
space:
mode:
authorDavid Walter Seikel2014-05-05 03:48:09 +1000
committerDavid Walter Seikel2014-05-05 03:48:09 +1000
commitab2fb9f9c5d16f60847225608a9b21156659d210 (patch)
treefa2d81082cc7074a96e56bb1b83bd73ff06d6086 /src/extantz/winFang.c
parentMerge the window handle creation code, and add proper hiding for them. (diff)
downloadSledjHamr-ab2fb9f9c5d16f60847225608a9b21156659d210.zip
SledjHamr-ab2fb9f9c5d16f60847225608a9b21156659d210.tar.gz
SledjHamr-ab2fb9f9c5d16f60847225608a9b21156659d210.tar.bz2
SledjHamr-ab2fb9f9c5d16f60847225608a9b21156659d210.tar.xz
winFang no longer depends on ourGlobals.
Diffstat (limited to '')
-rw-r--r--src/extantz/winFang.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/extantz/winFang.c b/src/extantz/winFang.c
index 3c4cc22..830b84e 100644
--- a/src/extantz/winFang.c
+++ b/src/extantz/winFang.c
@@ -67,19 +67,18 @@ void winFangShow(winFang *win)
67 evas_object_show(win->hand[i]); 67 evas_object_show(win->hand[i]);
68} 68}
69 69
70winFang *winFangAdd(globals *ourGlobals) 70winFang *winFangAdd(Evas_Object *parent)
71{ 71{
72 winFang *result; 72 winFang *result;
73 Evas_Object *bg; 73 Evas_Object *bg;
74 74
75 result = calloc(1, sizeof(winFang)); 75 result = calloc(1, sizeof(winFang));
76 eina_clist_add_head(&ourGlobals->winFangs, &result->node);
77 eina_clist_init(&result->widgets); 76 eina_clist_init(&result->widgets);
78 77
79 // In theory this should create an EWS window, in practice, I'm not seeing any difference. 78 // In theory this should create an EWS window, in practice, I'm not seeing any difference.
80 // Guess I'll have to implement my own internal window manager. I don't think a basic one will be that hard. Famous last words. 79 // Guess I'll have to implement my own internal window manager. I don't think a basic one will be that hard. Famous last words.
81// elm_config_engine_set("ews"); 80// elm_config_engine_set("ews");
82 result->win = elm_win_add(ourGlobals->win, "inlined", ELM_WIN_INLINED_IMAGE); 81 result->win = elm_win_add(parent, "inlined", ELM_WIN_INLINED_IMAGE);
83 // On mouse down we try to shift focus to the backing image, this seems to be the correct thing to force focus onto it's widgets. 82 // On mouse down we try to shift focus to the backing image, this seems to be the correct thing to force focus onto it's widgets.
84 // According to the Elm inlined image window example, this is what's needed to. 83 // According to the Elm inlined image window example, this is what's needed to.
85 evas_object_event_callback_add(elm_win_inlined_image_object_get(result->win), EVAS_CALLBACK_MOUSE_DOWN, _cb_mouse_down_elm, NULL); 84 evas_object_event_callback_add(elm_win_inlined_image_object_get(result->win), EVAS_CALLBACK_MOUSE_DOWN, _cb_mouse_down_elm, NULL);
@@ -96,7 +95,7 @@ winFang *winFangAdd(globals *ourGlobals)
96 return result; 95 return result;
97} 96}
98 97
99void winFangComplete(globals *ourGlobals, winFang *win, int x, int y, int w, int h) 98void winFangComplete(winFang *win, int x, int y, int w, int h)
100{ 99{
101 Evas_Object *obj = elm_win_inlined_image_object_get(win->win); 100 Evas_Object *obj = elm_win_inlined_image_object_get(win->win);
102 Evas_Object *obj2 = evas_object_evas_get(obj); 101 Evas_Object *obj2 = evas_object_evas_get(obj);
@@ -150,7 +149,7 @@ void winFangComplete(globals *ourGlobals, winFang *win, int x, int y, int w, int
150 } 149 }
151} 150}
152 151
153void winFangDel(globals *ourGlobals, winFang *win) 152void winFangDel(winFang *win)
154{ 153{
155 Widget *wid; 154 Widget *wid;
156 155