From fb5f3e694b0f6e2bccfc2124555c986fdc409cd0 Mon Sep 17 00:00:00 2001 From: Yuuki Harano Date: Tue, 13 Apr 2021 21:23:48 +0900 Subject: [PATCH] Workaround touchscreen events are ignored on sway On sway, gdk_device_get_window_at_position() in xg_event_is_for_scrollbar always returns NULL, and all the touchscreen press events are mishandled as on scrollbar. We don't need to call xg_event_is_for_scrollbar, so removed the call. * src/pgtkterm.c (button_event): Don't call xg_event_is_for_scrollbar. --- src/pgtkterm.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/pgtkterm.c b/src/pgtkterm.c index 10a3999f70d..55c139fb7ca 100644 --- a/src/pgtkterm.c +++ b/src/pgtkterm.c @@ -6496,8 +6496,13 @@ button_event (GtkWidget * widget, GdkEvent * event, gpointer * user_data) } } + /* xg_event_is_for_scrollbar() doesn't work correctly on sway, and + * we shouldn't need it. + */ +#if 0 if (f && xg_event_is_for_scrollbar (f, event)) f = 0; +#endif if (f) { -- 2.39.5