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 736569 - sidebar: Set default focus to From entry
sidebar: Set default focus to From entry
Status: RESOLVED FIXED
Product: gnome-maps
Classification: Applications
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: gnome-maps-maint
gnome-maps-maint
Depends on:
Blocks:
 
 
Reported: 2014-09-12 15:13 UTC by Damián Nohales
Modified: 2014-10-09 08:26 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
sidebar: Set default focus to From entry (1.42 KB, patch)
2014-09-12 15:13 UTC, Damián Nohales
reviewed Details | Review
sidebar: Set default focus to From entry (1.41 KB, patch)
2014-09-12 16:03 UTC, Damián Nohales
committed Details | Review

Description Damián Nohales 2014-09-12 15:13:27 UTC
This is pretty much obvious, when the sidebar is revealed, we usually want focus on the "From" entry, let's do that by default.
Comment 1 Damián Nohales 2014-09-12 15:13:36 UTC
Created attachment 286056 [details] [review]
sidebar: Set default focus to From entry
Comment 2 Zeeshan Ali 2014-09-12 15:27:02 UTC
Review of attachment 286056 [details] [review]:

::: src/sidebar.js
@@ +86,3 @@
+            if (this.child_revealed)
+                fromEntry.grab_focus();
+        }).bind(this));

couldn't we achieve the same by binding 'child-revealed' to fromEntry.has_focus?
Comment 3 Damián Nohales 2014-09-12 16:03:45 UTC
Created attachment 286060 [details] [review]
sidebar: Set default focus to From entry
Comment 4 Zeeshan Ali 2014-09-12 16:14:54 UTC
Review of attachment 286060 [details] [review]:

if you have tested it, ack
Comment 5 Jonas Danielsson 2014-09-12 16:24:40 UTC
Im not convinced.

If from should contain current location dont we want another entry focused? To, or first via?
Comment 6 Zeeshan Ali 2014-09-12 16:26:43 UTC
(In reply to comment #5)
> Im not convinced.
> 
> If from should contain current location dont we want another entry focused? To,
> or first via?

hmm.. true. but its still better than the current situation.
Comment 7 Damián Nohales 2014-09-12 16:45:57 UTC
(In reply to comment #5)
> Im not convinced.
> 
> If from should contain current location dont we want another entry focused? To,
> or first via?

I realized that too, but it would be a bit annoying if putting current location in "From" entry wasn't the pretended user action, user will need to go to From manually and tab to a previous widget (Shift+Tab) is not a common and easy action as tab to a next widget. We cannot know the pretended action, we have only one button to meet all routing claims.

If you reveal the sidebar, let's say, by pressing a "From here" button in a bubble or whatever, that's a different situation and I wouldn't set the focus in From.

I leave the patch as "Reviewed" until we agree.