diff options
author | Marcel Hollerbach <mail@marcel-hollerbach.de> | 2020-01-27 11:23:13 -0500 |
---|---|---|
committer | Christopher Michael <cp.michael@samsung.com> | 2020-01-27 11:23:13 -0500 |
commit | 7adcaedc081db2fd8c039b3e1416654d30b8b476 (patch) | |
tree | b5b461a3927959e784824ab35d4e2d84e0ae1043 | |
parent | 1b37f1504fe47ecd1c7f8736293c29afc01cd8aa (diff) | |
download | efl-7adcaedc081db2fd8c039b3e1416654d30b8b476.tar.gz |
ecore_wl2: only ungrab/grab on last/first down/up event
Summary: otherwise we are silently forgetting about up events.
Reviewers: zmike, devilhorns
Reviewed By: devilhorns
Subscribers: cedric, #reviewers, #committers
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D11199
-rw-r--r-- | src/lib/ecore_wl2/ecore_wl2_input.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/ecore_wl2/ecore_wl2_input.c b/src/lib/ecore_wl2/ecore_wl2_input.c index 75a7366f82..0e0e3ce0b7 100644 --- a/src/lib/ecore_wl2/ecore_wl2_input.c +++ b/src/lib/ecore_wl2/ecore_wl2_input.c @@ -1218,7 +1218,7 @@ _touch_cb_down(void *data, struct wl_touch *touch EINA_UNUSED, unsigned int seri _pointer_cb_enter(data, NULL, serial, surface, x, y); - if ((!input->grab.window) && (input->focus.touch)) + if ((!input->grab.window) && (input->focus.touch) && input->grab.touch_count == 1) { _ecore_wl2_input_grab(input, input->focus.touch, BTN_LEFT); input->grab.timestamp = timestamp; @@ -1246,7 +1246,7 @@ _touch_cb_up(void *data, struct wl_touch *touch EINA_UNUSED, unsigned int serial if (input->grab.count) input->grab.count--; if (input->grab.touch_count) input->grab.touch_count--; if ((input->grab.window) && (input->grab.button == BTN_LEFT) && - (!input->grab.count)) + (!input->grab.count) && !input->grab.touch_count) _ecore_wl2_input_ungrab(input); if (input->grab.touch_count == 0) input->focus.touch = NULL; |