Bug 1597791: Introduce autoFillAdaptiveHistory nimbus variable. r=adw

Differential Revision: https://phabricator.services.mozilla.com/D145704
This commit is contained in:
Daisuke Akatsuka 2022-05-13 22:46:37 +00:00
Родитель 6869007716
Коммит 2155a6e0d3
3 изменённых файлов: 7 добавлений и 2 удалений

Просмотреть файл

@ -46,7 +46,8 @@ const PREF_URLBAR_DEFAULTS = new Map([
// textbox. If false, autofill will be disabled.
["autoFill", true],
// Whether enabling adaptive history autofill.
// Whether enabling adaptive history autofill. This pref is a fallback for the
// Nimbus variable `autoFillAdaptiveHistoryEnabled`.
["autoFill.adaptiveHistory.enabled", false],
// Threshold for use count of input history that we handle as adaptive history

Просмотреть файл

@ -752,7 +752,7 @@ class ProviderAutofill extends UrlbarProvider {
}
// We try to autofill with adaptive history first.
if (UrlbarPrefs.get("autoFill.adaptiveHistory.enabled")) {
if (UrlbarPrefs.get("autoFillAdaptiveHistoryEnabled")) {
const [query, params] = this._getAdaptiveHistoryQuery(queryContext);
if (query) {
const resultSet = await conn.executeCached(query, params);

Просмотреть файл

@ -34,6 +34,10 @@ urlbar:
the event is recorded once per app session when the user first encounters
the UI of the experiment in which they're enrolled.
variables:
autoFillAdaptiveHistoryEnabled:
type: boolean
fallbackPref: browser.urlbar.autoFill.adaptiveHistory.enabled
description: Whether enabling adaptive history autofill.
bestMatchBlockingEnabled:
type: boolean
fallbackPref: browser.urlbar.bestMatch.blockingEnabled