After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 691763 - Text field shouldn't be selected by default
Text field shouldn't be selected by default
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: Sharing
3.7.x
Other Linux
: Normal normal
: ---
Assigned To: Control-Center Maintainers
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-01-15 07:43 UTC by Bastien Nocera
Modified: 2013-01-29 16:24 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
sharing: avoid focusing the CcHostnameEntry widget when the panel is shown (1.40 KB, patch)
2013-01-21 16:59 UTC, Thomas Wood
needs-work Details | Review
sharing: avoid focusing the CcHostnameEntry widget when the panel is shown (919 bytes, patch)
2013-01-25 16:11 UTC, Thomas Wood
committed Details | Review

Description Bastien Nocera 2013-01-15 07:43:19 UTC
Makes it too easy to change the machine's name. Perhaps it should be behind a button (similarly to the user name in the user accounts panel for example).
Comment 1 Thomas Wood 2013-01-21 16:59:38 UTC
Created attachment 234029 [details] [review]
sharing: avoid focusing the CcHostnameEntry widget when the panel is shown
Comment 2 Thomas Wood 2013-01-21 17:03:28 UTC
Review of attachment 234029 [details] [review]:

This patch fixes the primary issue at least until further design review can be done.
Comment 3 Bastien Nocera 2013-01-23 10:01:45 UTC
Review of attachment 234029 [details] [review]:

I don't really like focus hacks like this one, and I would really rather we looked into using the button/entry combo used in the user accounts.
Comment 4 Thomas Wood 2013-01-23 10:10:41 UTC
The original design was from Jon McCann, so adding him to CC for comment.
Comment 5 Bastien Nocera 2013-01-23 12:24:23 UTC
Another way to deal with this would be to look in the focus chain, and focus the next item in line.
Comment 6 Thomas Wood 2013-01-25 16:11:13 UTC
Created attachment 234423 [details] [review]
sharing: avoid focusing the CcHostnameEntry widget when the panel is shown

Alternative patch to focus the main list box (which is the next item in the
focus chain). Specifying the list box directly should probably result in more
consistent behaviour.
Comment 7 Bastien Nocera 2013-01-29 10:30:43 UTC
Review of attachment 234423 [details] [review]:

::: panels/sharing/cc-sharing-panel.c
@@ +773,3 @@
+
+  g_signal_connect_swapped (self, "map", G_CALLBACK (gtk_widget_grab_focus),
+                            WID ("main-list-box"));

Should select a focusable widget instead.
Comment 8 Thomas Wood 2013-01-29 14:54:41 UTC
(In reply to comment #7)
> Review of attachment 234423 [details] [review]:
> 
> ::: panels/sharing/cc-sharing-panel.c
> @@ +773,3 @@
> +
> +  g_signal_connect_swapped (self, "map", G_CALLBACK (gtk_widget_grab_focus),
> +                            WID ("main-list-box"));
> 
> Should select a focusable widget instead.

The EggListBox is the only focusable widget in this case (the children are just containers with labels).
Comment 9 Thomas Wood 2013-01-29 16:23:58 UTC
Attachment 234423 [details] pushed as b22c18e - sharing: avoid focusing the CcHostnameEntry widget when the panel is shown