Ctrl+F should focus the preferences search input

VERIFIED FIXED in Firefox 57

Status

()

defect
VERIFIED FIXED
2 years ago
2 years ago

People

(Reporter: MikkCZ, Assigned: prathiksha)

Tracking

(Blocks 1 bug)

unspecified
Firefox 57
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox57 verified)

Details

Attachments

(1 attachment)

STR:
1) Open about:preferences.
2) Switch e.g. to privacy and back to general (just to loose focus from the search field).
3) Press Ctrl+F.

Now I would expect to open search toolbar down the window to search the preferences, or focus the preferences search input again, but nothing happens. Only when you are in Files & Application (newly in General), the File/application type search field is focused, which I would not expect to happen at all.
Duplicate of this bug: 1389322
Assignee: nobody → prathikshaprasadsuman
Attachment #8896896 - Flags: review?(jaws)
Status: NEW → ASSIGNED
Comment on attachment 8896896 [details]
Bug 1382566 - Ctrl+F should focus the preferences search input.

https://reviewboard.mozilla.org/r/168180/#review173576

::: browser/components/preferences/in-content-new/findInPage.js:23
(Diff revision 1)
> -        this.searchInput.focus();
> +        this.focusSearchInput();
>        });
>        // Initialize other panes in an idle callback.
>        window.requestIdleCallback(() => this.initializeCategories());
>      }
>      let strings = this.strings;
>      this.searchInput.placeholder = AppConstants.platform == "win" ?
>        strings.getString("searchInput.labelWin") :
>        strings.getString("searchInput.labelUnix");
>    },
>  
> +  focusSearchInput() {
> +    this.searchInput.focus();
> +  },

Please undo these changes. Calling `this.searchInput.focus();` is fine as-is.

::: browser/components/preferences/in-content-new/main.xul:650
(Diff revision 1)
> -  <!-- Ctrl+f/k focus the search box in the Applications pane.
> -       These <key>s have oncommand attributes because of bug 371900. -->
> +  <!-- Ctrl + k focuses on the Files and Applications search box in the General pane.
> +       This key has oncommand attribute because of bug 371900. -->
> -  <key key="&focusSearch1.key;" modifiers="accel" id="focusSearch1" oncommand=";"/>
>    <key key="&focusSearch2.key;" modifiers="accel" id="focusSearch2" oncommand=";"/>

It's not clear to me why we would keep Ctrl+K working to focus the Files and Applications search.

::: browser/components/preferences/in-content-new/preferences.xul:175
(Diff revision 1)
>          <label class="category-name" flex="1">&paneSync1.title;</label>
>        </richlistitem>
>      </richlistbox>
>  
>      <keyset>
> -      <!-- Disable the findbar because it doesn't work properly.
> +      <key key="&focusSearch1.key;" modifiers="accel" id="focusSearch1" oncommand="gSearchResultsPane.focusSearchInput();"/>

gSearchResultsPane.searchInput.focus();
Attachment #8896896 - Flags: review?(jaws) → review-
Comment on attachment 8896896 [details]
Bug 1382566 - Ctrl+F should focus the preferences search input.

https://reviewboard.mozilla.org/r/168180/#review173576

> It's not clear to me why we would keep Ctrl+K working to focus the Files and Applications search.

I was not sure about what to do with Ctrl + K. Should I remove it ?
Comment on attachment 8896896 [details]
Bug 1382566 - Ctrl+F should focus the preferences search input.

https://reviewboard.mozilla.org/r/168180/#review173690

Can you please remove focusSearch2 from the following places, with the exception of config.dtd and config.xul?

http://searchfox.org/mozilla-central/search?q=focusSearch2.key&case=false&regexp=false&path=
Attachment #8896896 - Flags: review?(jaws) → review-
Comment on attachment 8896896 [details]
Bug 1382566 - Ctrl+F should focus the preferences search input.

https://reviewboard.mozilla.org/r/168180/#review174138

Looks good, thanks!
Attachment #8896896 - Flags: review?(jaws) → review+
Keywords: checkin-needed
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/adce349dfe86
Ctrl+F should focus the preferences search input. r=jaws
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/adce349dfe86
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 57
Duplicate of this bug: 1375888
Verified as fixed using the latest Nightly 57.0a1 (2017-08-22) on Ubuntu 16.04 x64, Windows 10 x64 and Mac OS X 10.12.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.