[gnome-control-center] sharing: avoid focusing the CcHostnameEntry widget when the panel is shown



commit b22c18e230377acad97dc2a5b18ba893298e04fb
Author: Thomas Wood <thomas wood intel com>
Date:   Tue Jan 29 16:23:17 2013 +0000

    sharing: avoid focusing the CcHostnameEntry widget when the panel is shown
    
    https://bugzilla.gnome.org/show_bug.cgi?id=691763

 panels/sharing/cc-sharing-panel.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/panels/sharing/cc-sharing-panel.c b/panels/sharing/cc-sharing-panel.c
index 7a5452c..1ad4d42 100644
--- a/panels/sharing/cc-sharing-panel.c
+++ b/panels/sharing/cc-sharing-panel.c
@@ -815,6 +815,10 @@ cc_sharing_panel_init (CcSharingPanel *self)
     cc_sharing_panel_setup_screen_sharing_dialog (self);
   else
     gtk_widget_hide (WID ("screen-sharing-button"));
+
+  /* make sure the hostname entry isn't focused by default */
+  g_signal_connect_swapped (self, "map", G_CALLBACK (gtk_widget_grab_focus),
+                            WID ("main-list-box"));
 }
 
 CcSharingPanel *



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