spinbutton: Make the swipe gesture only work on touch devices
This code was relying on the previous GtkGestureSingle::touch-only default value. https://bugzilla.gnome.org/show_bug.cgi?id=734285
This commit is contained in:
@ -724,6 +724,7 @@ gtk_spin_button_init (GtkSpinButton *spin_button)
|
||||
gtk_widget_add_events (GTK_WIDGET (spin_button), GDK_SCROLL_MASK);
|
||||
|
||||
priv->swipe_gesture = gtk_gesture_swipe_new (GTK_WIDGET (spin_button));
|
||||
gtk_gesture_single_set_touch_only (GTK_GESTURE_SINGLE (priv->swipe_gesture), TRUE);
|
||||
gtk_event_controller_set_propagation_phase (GTK_EVENT_CONTROLLER (priv->swipe_gesture),
|
||||
GTK_PHASE_CAPTURE);
|
||||
g_signal_connect (priv->swipe_gesture, "begin",
|
||||
|
||||
Reference in New Issue
Block a user