[nautilus] nautilus-window-slot: Don't grab focus on view change



commit 982469e3ae060885b271ef193ca60dfc28e66749
Author: Carlos Soriano <csoriano gnome org>
Date:   Mon Feb 2 14:15:52 2015 +0100

    nautilus-window-slot: Don't grab focus on view change
    
    We were grabbing the focus on view mode change, so if the user changed
    the view mode with keyboard he could continue using it.
    But it makes the problem that with the new popover menu in the toolbar
    where you can choose between different views while the menu is open,
    grabbing the focus to another widget dismiss the menu, which is
    against the behavior of the GtkMenuPopover.
    
    To fix that, don't grab focus on view changes.
    
    In the tests I have done, you can still focus the view just using the
    arrows after the view changes, so I don't think it will be a problem for
    keyboard users.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=743591

 src/nautilus-window-slot.c |    5 -----
 1 files changed, 0 insertions(+), 5 deletions(-)
---
diff --git a/src/nautilus-window-slot.c b/src/nautilus-window-slot.c
index 93ea872..c037cf3 100644
--- a/src/nautilus-window-slot.c
+++ b/src/nautilus-window-slot.c
@@ -2348,11 +2348,6 @@ nautilus_window_slot_switch_new_content_view (NautilusWindowSlot *slot)
                widget = GTK_WIDGET (slot->details->content_view);
                gtk_container_add (GTK_CONTAINER (slot->details->view_overlay), widget);
                gtk_widget_show (widget);
-
-               if (!NAUTILUS_IS_SEARCH_DIRECTORY (nautilus_view_get_model (slot->details->content_view)) &&
-                   slot == nautilus_window_get_active_slot (window)) {
-                       nautilus_view_grab_focus (slot->details->content_view);
-               }
        }
 }
 


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