[nautilus/clear-starred-column-header: 2/2] list-view: Make Starred column non-resizable




commit 41f073f7104eab667269b2b33a5726a299ef6588
Author: António Fernandes <antoniof gnome org>
Date:   Sat Feb 13 09:40:48 2021 +0000

    list-view: Make Starred column non-resizable
    
    There is only a 16px symbol, so there is nothing to gain from making it
    wider. And making it narrower makes the overlay scrollbar stand in the
    way of the stars.

 src/nautilus-list-view.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/src/nautilus-list-view.c b/src/nautilus-list-view.c
index d0793d5a6..6ba067f44 100644
--- a/src/nautilus-list-view.c
+++ b/src/nautilus-list-view.c
@@ -2321,7 +2321,10 @@ create_and_set_up_tree_view (NautilusListView *view)
         }
         else
         {
-            if (g_strcmp0 (name, "starred") == 0)
+            gboolean is_starred_column;
+
+            is_starred_column = g_strcmp0 (name, "starred") == 0;
+            if (is_starred_column)
             {
                 cell = gtk_cell_renderer_pixbuf_new ();
                 g_object_set (cell,
@@ -2374,7 +2377,7 @@ create_and_set_up_tree_view (NautilusListView *view)
                               G_CALLBACK (on_column_header_event),
                               view);
 
-            gtk_tree_view_column_set_resizable (column, TRUE);
+            gtk_tree_view_column_set_resizable (column, !is_starred_column);
             gtk_tree_view_column_set_sort_order (column, sort_order);
 
             if (!strcmp (name, "where"))


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]