Register the new window into out evas.

Summary:
Otherwise the mouse up event is emitted to the evas but the evas does
not work with it, because it does not know the window it is from. This
leads to a evas_event_down_count_get bigger than 1 which leads to a
missing mouse_out event. With this missing mouse_out event _post_up_handle
in evas_event.c is not called anymore, this means all the click events
are getting emitted to the object which was last clicked.

This fixes T1894.

Test Plan: Drag and Drop a icon somewhere and click somewhere after that, the evas will not get stuck anymore

Reviewers: raster

Subscribers: cedric, abyomi0, zmike, raster

Maniphest Tasks: T1894

Differential Revision: https://phab.enlightenment.org/D1771
This commit is contained in:
Marcel Hollerbach 2014-12-12 09:39:51 +01:00
parent 003e521b70
commit 367eea52ec
1 changed files with 3 additions and 0 deletions

View File

@ -285,6 +285,8 @@ e_drag_start(E_Drag *drag, int x, int y)
_drag_win = ecore_x_window_input_new(drag->comp->win,
drag->comp->man->x, drag->comp->man->y,
drag->comp->man->w, drag->comp->man->h);
ecore_event_window_register(_drag_win, drag->comp->ee, drag->comp->evas,
NULL, NULL, NULL, NULL);
ecore_x_window_show(_drag_win);
#endif
_drag_win_root = drag->comp->man->root;
@ -1153,6 +1155,7 @@ _e_drag_free(E_Drag *drag)
eina_stringshare_del(drag->types[i]);
free(drag);
#ifndef HAVE_WAYLAND_ONLY
ecore_event_window_unregister(_drag_win);
ecore_x_window_free(_drag_win);
ecore_x_window_shadow_tree_flush();
#endif