These bugs appear to be abandoned. Retargeting to 2.20
Target Milestone: Bugzilla 2.18 → Bugzilla 2.20
Trivial. Patch coming up.
Assignee: nobody → kiko
Target Milestone: Bugzilla 2.20 → Bugzilla 2.18
Created attachment 144226 [details] [diff] [review] kiko_v1: add focus() call to onLoad handler. Tested and works. Shouldn't be any cross-browser issues -- it's the same DOM access we use for the form selection JS.
This is not necessarily a good thing, for the following reason: if a page takes a couple of seconds to load (as our query page does, being very big), and you've already clicked somewhere and started typing, the focus gets stolen from you, which is really irritating. Can we detect whether that has happened before calling focus()? (For something like www.google.com, which is tiny, it's fine.) Gerv
Comment on attachment 144226 [details] [diff] [review] kiko_v1: add focus() call to onLoad handler. Gerv has a point; this is even painful on Google sometimes. Can we do this right after displaying the summary field rather than after the page has been loaded?
With the advent of the new fulltext search, I'm usually using that when I need to do a "quick" query on something easy. When I go to the Advanced Query page, I typically want to do something advanced, and most of the time it's somewhere below the top screen of the page. First thing I generally do when the query page loads is hit the space bar to page down. That gets broken if the summary field focuses. That said, I'd be all for focusing the "enter some words" field on the fulltext search page, since the entire page (mostly) fits in the browser window, and the fulltext search will be the default search page when 2.18 ships.
So what do I do now?
Another alternative is using inline script to focus the search form, which would be invoked early (and not late as onLoad is). It could even be placed right after rendering the search box (which is parsed early) to ensure nothing else could have been focused (unless in the reload case). How does that sound?
Inline script sounds like a good idea. Gerv
Created attachment 146128 [details] [diff] [review] kiko_v2: inline script Glad you liked it.
Attachment #144226 - Attachment is obsolete: true
Created attachment 146132 [details] [diff] [review] kiko_v3: less braindead version for both specific and "regular" query This is less broken, and does it for both pages.
Attachment #146128 - Attachment is obsolete: true
Comment on attachment 146132 [details] [diff] [review] kiko_v3: less braindead version for both specific and "regular" query Low-risk and a nice usability touch.
Attachment #146132 - Flags: review?(gerv)
Comment on attachment 146132 [details] [diff] [review] kiko_v3: less braindead version for both specific and "regular" query r=gerv. Gerv
Attachment #146132 - Flags: review?(gerv) → review+
I still have my reservations on doing this on the advanced query page, but I suppose we can back it out later if we get a lot of complaints.
Flags: approval? → approval+
checked in for kiko, since he's off wandering Europe somewhere. :) Checking in template/en/default/search/form.html.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/en/default/search/form.html.tmpl,v <-- form.html.tmpl new revision: 1.23; previous revision: 1.22 done Checking in template/en/default/search/search-specific.html.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/en/default/search/search-specific.html.tmpl,v <-- search-specific.html.tmpl new revision: 1.6; previous revision: 1.5 done
Status: NEW → RESOLVED
Last Resolved: 14 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.