From ebd1840802a11f1f0b668064f4ba3c014c47c045 Mon Sep 17 00:00:00 2001 From: Carlos Garnacho Date: Mon, 21 Oct 2019 17:09:17 +0200 Subject: [PATCH] scrollcontroller: Set scroll event mask on scroll controller This ensures adding the controller to a widget will end up with the expected event masks in the widget default window. --- gtk/gtkeventcontrollerscroll.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gtk/gtkeventcontrollerscroll.c b/gtk/gtkeventcontrollerscroll.c index 91831f404f..9e90b54dd7 100644 --- a/gtk/gtkeventcontrollerscroll.c +++ b/gtk/gtkeventcontrollerscroll.c @@ -455,6 +455,9 @@ gtk_event_controller_scroll_init (GtkEventControllerScroll *scroll) { scroll->scroll_history = g_array_new (FALSE, FALSE, sizeof (ScrollHistoryElem)); + gtk_event_controller_set_event_mask (GTK_EVENT_CONTROLLER (scroll), + GDK_SCROLL_MASK | + GDK_SMOOTH_SCROLL_MASK); } /**