Closed Bug 1598271 Opened 6 years ago Closed 5 years ago

Let webextension be able to filter browser.search.get() returned search engines unchecked in One-Click Search Engines options

Categories

(WebExtensions :: General, enhancement, P3)

70 Branch
enhancement

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: tiansheng111, Unassigned)

References

Details

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:70.0) Gecko/20100101 Firefox/70.0

Steps to reproduce:

  1. Open options page - Search - One-Click Search Engines
  2. Uncheck some search engine, Twitter for example
  3. Invoke [search.get()](https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/search/get) in WebExtension

Actual results:

A list of search engines returned by search.get() including Twitter

Expected results:

Twitter not included in search.get return value. Or some data field tell me the search engine is unchecked.

Mike, what do you think of this enhancement?

Flags: needinfo?(mconnor)

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → Search
Product: WebExtensions → Firefox
Component: Search → General
Product: Firefox → WebExtensions
Priority: -- → P3
Whiteboard: webext?

Removed webext? from whiteboard, this issue is currently waiting for an answer to the needinfo.

Whiteboard: webext?

Re-reading this, the checkmark is for one-click, which makes the engine appear in the urlbar. Unchecking it does not disable the engine or the addon, so it is legitimate that the search api still returns it.

Status: UNCONFIRMED → RESOLVED
Closed: 5 years ago
Flags: needinfo?(mconnor)
Resolution: --- → WONTFIX

(In reply to Shane Caraveo (:mixedpuppy) from comment #4)

Re-reading this, the checkmark is for one-click, which makes the engine appear in the urlbar. Unchecking it does not disable the engine or the addon, so it is legitimate that the search api still returns it.

So, may add-ons have another attribute returned to know weather the checkmark is on or off?

Sometimes, after upgrade Firefox, the search engines may just re-appear to the list even user removed them. So many user would prefer to uncheck them instead of simply remove them.

Current behavior makes user confused: Since search engines unchecked will not appear in their address bar nor search bar, but they will be listed with add-ons. Yes, each add-ons may implement an extra options user interface for checking which search engines would be used. But the options UI would be a duplicate and annoying thing to both extension developers and users. Also, with such an UI, extensions may not properly handle newly added search engines: Neither active them by default nor inactive them by default is a good option to add-ons. That's why it would be make sense to at least include the state of the checkmark.

(In reply to Tian, Sheng from comment #5)

Current behavior makes user confused: Since search engines unchecked will not appear in their address bar nor search bar, but they will be listed with add-ons. Yes, each add-ons may implement an extra options user interface for checking which search engines would be used. But the options UI would be a duplicate and annoying thing to both extension developers and users. Also, with such an UI, extensions may not properly handle newly added search engines: Neither active them by default nor inactive them by default is a good option to add-ons. That's why it would be make sense to at least include the state of the checkmark.

We're currently revisiting the search preferences and this check-mark option may or may not change/stay. We haven't decided just yet, but I wouldn't want to expose it at this time in case we decide to change how it functions or remove it (note: we're aware of how users use it, and we will take that into our considerations).

I'm hoping for a decision sometime this year, though it may go into next. I'll note this down as something to reconsider once the decision is made.

You need to log in before you can comment on or make changes to this bug.