summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@osg.samsung.com>2015-11-05 15:28:50 -0500
committerMike Blumenkrantz <zmike@osg.samsung.com>2015-11-05 15:31:16 -0500
commitf343a5403d49041de9010b15d88ee0388747e990 (patch)
treea77244787bbd090481415059a4b7084b96b91d5f
parent5f3278eba867ff7743512e27568f2c9f58c630c2 (diff)
account for window position in efm window drag initial positioning
fix T2819
-rw-r--r--src/bin/e_fm.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/bin/e_fm.c b/src/bin/e_fm.c
index 34b173ed2..52b5c1c1d 100644
--- a/src/bin/e_fm.c
+++ b/src/bin/e_fm.c
@@ -7609,6 +7609,7 @@ _e_fm2_cb_icon_mouse_move(void *data, Evas *e, Evas_Object *obj EINA_UNUSED, voi
7609 Eina_Binbuf *sbuf; 7609 Eina_Binbuf *sbuf;
7610 Eina_List *sl, *icons = NULL; 7610 Eina_List *sl, *icons = NULL;
7611 size_t sel_length = 0, p_offset, p_length; 7611 size_t sel_length = 0, p_offset, p_length;
7612 int wx = 0, wy = 0;
7612 7613
7613 ic->sd->drag = EINA_TRUE; 7614 ic->sd->drag = EINA_TRUE;
7614 ic->drag.start = EINA_FALSE; 7615 ic->drag.start = EINA_FALSE;
@@ -7712,10 +7713,13 @@ _e_fm2_cb_icon_mouse_move(void *data, Evas *e, Evas_Object *obj EINA_UNUSED, voi
7712 d = e_drag_new(0, 0, drag_types, 1, 7713 d = e_drag_new(0, 0, drag_types, 1,
7713 sel, sel_length, NULL, _e_fm2_cb_drag_finished); 7714 sel, sel_length, NULL, _e_fm2_cb_drag_finished);
7714 d->button_mask = evas_pointer_button_down_mask_get(e); 7715 d->button_mask = evas_pointer_button_down_mask_get(e);
7716 if (ic->sd->win)
7717 evas_object_geometry_get(ic->sd->win, &wx, &wy, NULL, NULL);
7715 if (layout) 7718 if (layout)
7716 d->x = ic->sd->x, d->y = ic->sd->y; 7719 d->x = ic->sd->x, d->y = ic->sd->y;
7717 else 7720 else
7718 d->x = ic->x + ic->sd->x - ic->sd->pos.x, d->y = ic->y + ic->sd->y - ic->sd->pos.y; 7721 d->x = ic->x + ic->sd->x - ic->sd->pos.x, d->y = ic->y + ic->sd->y - ic->sd->pos.y;
7722 d->x += wx, d->y += wy;
7719#ifndef HAVE_WAYLAND_ONLY 7723#ifndef HAVE_WAYLAND_ONLY
7720 e_drop_handler_action_set(ECORE_X_ATOM_XDND_ACTION_MOVE); 7724 e_drop_handler_action_set(ECORE_X_ATOM_XDND_ACTION_MOVE);
7721#endif 7725#endif
@@ -7738,8 +7742,8 @@ _e_fm2_cb_icon_mouse_move(void *data, Evas *e, Evas_Object *obj EINA_UNUSED, voi
7738 e_drag_key_up_cb_set(d, _e_fm_drag_key_up_cb); 7742 e_drag_key_up_cb_set(d, _e_fm_drag_key_up_cb);
7739 7743
7740 e_drag_xdnd_start(d, 7744 e_drag_xdnd_start(d,
7741 ic->drag.x + ic->x + ic->sd->x - ic->sd->pos.x, 7745 ic->drag.x + wx + ic->x + ic->sd->x - ic->sd->pos.x,
7742 ic->drag.y + ic->y + ic->sd->y - ic->sd->pos.y); 7746 ic->drag.y + wy + ic->y + ic->sd->y - ic->sd->pos.y);
7743 } 7747 }
7744 } 7748 }
7745} 7749}