discomfitor pushed a commit to branch master. http://git.enlightenment.org/core/enlightenment.git/commit/?id=d689ab5e757fb5215e763fb3fc8cea0c4c66dca5
commit d689ab5e757fb5215e763fb3fc8cea0c4c66dca5 Author: Mike Blumenkrantz <zm...@osg.samsung.com> Date: Thu Jan 21 12:52:21 2016 -0500 track wayland client mouse button states as a full button mask sending a button release event to a surface which has not previously received a button press yields strange results --- src/bin/e_comp_wl.c | 8 ++++++++ src/bin/e_comp_wl.h | 1 + 2 files changed, 9 insertions(+) diff --git a/src/bin/e_comp_wl.c b/src/bin/e_comp_wl.c index 73f943d..6af7bb9 100644 --- a/src/bin/e_comp_wl.c +++ b/src/bin/e_comp_wl.c @@ -3099,6 +3099,14 @@ e_comp_wl_evas_handle_mouse_button(E_Client *ec, uint32_t timestamp, uint32_t bu break; } + if (state == WL_POINTER_BUTTON_STATE_PRESSED) + e_comp_wl->ptr.button_mask |= 1 << button_id; + else + { + /* reject release events if button is not pressed */ + if (!(e_comp_wl->ptr.button_mask & (1 << button_id))) return EINA_FALSE; + e_comp_wl->ptr.button_mask &= ~(1 << button_id); + } e_comp_wl->ptr.button = btn; if (!ec->comp_data->surface) return EINA_FALSE; diff --git a/src/bin/e_comp_wl.h b/src/bin/e_comp_wl.h index d280eb3..48c085f 100644 --- a/src/bin/e_comp_wl.h +++ b/src/bin/e_comp_wl.h @@ -167,6 +167,7 @@ struct _E_Comp_Wl_Data wl_fixed_t x, y; wl_fixed_t grab_x, grab_y; uint32_t button; + uint32_t button_mask; E_Client *ec; Eina_Bool enabled : 1; } ptr; --