summaryrefslogtreecommitdiff
path: root/gtk/gtktreeview.c
diff options
context:
space:
mode:
authorCarlos Garnacho <carlosg@gnome.org>2014-08-27 14:36:53 +0200
committerCarlos Garnacho <carlosg@gnome.org>2014-08-27 17:12:52 +0200
commite6199af60d4f1be2aa538840674ed6a7932c704f (patch)
treebf4b5b2045f5095355cc23d7fc7f37639034457c /gtk/gtktreeview.c
parent79c3ff3c4ed74bbcc820dac2d5180fa4d48d55ec (diff)
downloadgtk+-e6199af60d4f1be2aa538840674ed6a7932c704f.tar.gz
treeview: Reset multipress controller after 2nd click
The pre-gestures code used to compare the current button press with the previous one on !activate_on_single_click, and unset the previous event data so ::row-activated would be emitted every 2 clicks. So do the same with the multipress gesture and reset it after every 2nd click to have ::row-activated emitted multiple times while manic clicking. https://bugzilla.gnome.org/show_bug.cgi?id=735353
Diffstat (limited to 'gtk/gtktreeview.c')
-rw-r--r--gtk/gtktreeview.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gtk/gtktreeview.c b/gtk/gtktreeview.c
index efaabfb33c..48cdede79f 100644
--- a/gtk/gtktreeview.c
+++ b/gtk/gtktreeview.c
@@ -3308,6 +3308,9 @@ gtk_tree_view_multipress_gesture_pressed (GtkGestureMultiPress *gesture,
}
gtk_tree_path_free (path);
+
+ if (n_press >= 2)
+ gtk_event_controller_reset (GTK_EVENT_CONTROLLER (gesture));
}
static void