[gnome-shell/wip/carlosg/osk-emoji-and-keypad: 28/40] st: Honor button mask on touch events
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/carlosg/osk-emoji-and-keypad: 28/40] st: Honor button mask on touch events
- Date: Sat, 26 Jan 2019 13:14:27 +0000 (UTC)
commit b34b29ef67ef9f57b79966c5c5e8143e73e743dc
Author: Carlos Garnacho <carlosg gnome org>
Date: Mon Jan 21 20:36:22 2019 +0100
st: Honor button mask on touch events
Even though it's not a "button", we use button1 to map to actions. Seems
fair to refuse to press the StButton if it would not react to button1.
src/st/st-button.c | 2 ++
1 file changed, 2 insertions(+)
---
diff --git a/src/st/st-button.c b/src/st/st-button.c
index a95ddff2d..5a70f4e83 100644
--- a/src/st/st-button.c
+++ b/src/st/st-button.c
@@ -241,6 +241,8 @@ st_button_touch_event (ClutterActor *actor,
if (priv->pressed != 0)
return CLUTTER_EVENT_PROPAGATE;
+ if ((priv->button_mask & mask) == 0)
+ return CLUTTER_EVENT_PROPAGATE;
device = clutter_event_get_device ((ClutterEvent*) event);
sequence = clutter_event_get_event_sequence ((ClutterEvent*) event);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]