[nautilus/wip/ernestask/list-view-rubberband] list-view: Enable rubberband selection
- From: Ernestas Kulik <ernestask src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus/wip/ernestask/list-view-rubberband] list-view: Enable rubberband selection
- Date: Wed, 1 May 2019 18:54:31 +0000 (UTC)
commit d2bebff63430b9349564c7093dac8b153c7511af
Author: Ernestas Kulik <ekulik redhat com>
Date: Wed May 1 20:53:32 2019 +0200
list-view: Enable rubberband selection
Related: https://bugzilla.gnome.org/show_bug.cgi?id=350618
src/nautilus-list-view.c | 7 +++++++
1 file changed, 7 insertions(+)
---
diff --git a/src/nautilus-list-view.c b/src/nautilus-list-view.c
index 9b7b7826b..493fb7c6f 100644
--- a/src/nautilus-list-view.c
+++ b/src/nautilus-list-view.c
@@ -551,6 +551,12 @@ on_tree_view_multi_press_gesture_pressed (GtkGestureMultiPress *gesture,
view->details->last_event_button_x = bin_x;
view->details->last_event_button_y = bin_y;
+ if (gtk_tree_view_is_blank_at_pos (tree_view, bin_x, bin_y, NULL, NULL, NULL, NULL))
+ {
+ nautilus_view_set_selection (NAUTILUS_VIEW (view), NULL);
+ return;
+ }
+
/* Don't handle extra mouse buttons here */
if (button > 5)
{
@@ -2118,6 +2124,7 @@ create_and_set_up_tree_view (NautilusListView *view)
(GDestroyNotify) g_free,
NULL);
gtk_tree_view_set_enable_search (view->details->tree_view, FALSE);
+ gtk_tree_view_set_rubber_banding (view->details->tree_view, TRUE);
view->details->drag_dest =
nautilus_tree_view_drag_dest_new (view->details->tree_view);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]