aboutsummaryrefslogtreecommitdiffstats
path: root/legacy/elementary/src/lib/elm_win.c
diff options
context:
space:
mode:
authorCarsten Haitzler <raster@rasterman.com>2011-03-23 13:29:26 +0000
committerCarsten Haitzler <raster@rasterman.com>2011-03-23 13:29:26 +0000
commit2fda5e577ff4509b533bb543e294e1a32405ac89 (patch)
treec5556d4868fee3a8fd5ee88bef65e25711dcbd44 /legacy/elementary/src/lib/elm_win.c
parentelementary/default.edc - fixed typo (ctxpopup) (diff)
downloadefl-2fda5e577ff4509b533bb543e294e1a32405ac89.tar.gz
listen to move events and track on override-redirect windows.
SVN revision: 58032
Diffstat (limited to 'legacy/elementary/src/lib/elm_win.c')
-rw-r--r--legacy/elementary/src/lib/elm_win.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/legacy/elementary/src/lib/elm_win.c b/legacy/elementary/src/lib/elm_win.c
index bf23098341..845f5bd93f 100644
--- a/legacy/elementary/src/lib/elm_win.c
+++ b/legacy/elementary/src/lib/elm_win.c
@@ -287,6 +287,22 @@ _elm_win_obj_intercept_show(void *data __UNUSED__, Evas_Object *obj)
}
static void
+_elm_win_obj_callback_move(void *data, Evas *e __UNUSED__, Evas_Object *obj, void *event_info __UNUSED__)
+{
+ Elm_Win *win = data;
+
+ if (ecore_evas_override_get(win->ee))
+ {
+ Evas_Coord x, y;
+
+ evas_object_geometry_get(obj, &x, &y, NULL, NULL);
+ win->screen.x = x;
+ win->screen.y = y;
+ evas_object_smart_callback_call(win->win_obj, "moved", NULL);
+ }
+}
+
+static void
_elm_win_delete_request(Ecore_Evas *ee)
{
Evas_Object *obj = ecore_evas_object_associate_get(ee);
@@ -1078,6 +1094,8 @@ elm_win_add(Evas_Object *parent, const char *name, Elm_Win_Type type)
_elm_win_obj_callback_show, win);
evas_object_event_callback_add(win->win_obj, EVAS_CALLBACK_DEL,
_elm_win_obj_callback_del, win);
+ evas_object_event_callback_add(win->win_obj, EVAS_CALLBACK_MOVE,
+ _elm_win_obj_callback_move, win);
ecore_evas_name_class_set(win->ee, name, _elm_appname);
ecore_evas_callback_delete_request_set(win->ee, _elm_win_delete_request);