forked from AuroraMiddleware/gtk
gtklabel: Don't accept unhandled mouse buttons
If the pressed mouse button neither triggers a context menu nor activates a link, set the sequence's state to DENIED. https://bugzilla.gnome.org/show_bug.cgi?id=742010
This commit is contained in:
parent
9474215a43
commit
57714b9774
@ -4956,6 +4956,11 @@ gtk_label_multipress_gesture_pressed (GtkGestureMultiPress *gesture,
|
||||
gtk_label_select_word (label);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gtk_gesture_set_state (GTK_GESTURE (gesture), GTK_EVENT_SEQUENCE_DENIED);
|
||||
return;
|
||||
}
|
||||
|
||||
if (n_press >= 3)
|
||||
gtk_event_controller_reset (GTK_EVENT_CONTROLLER (gesture));
|
||||
|
Loading…
Reference in New Issue
Block a user