зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1846787 - let shopping code ride the train (disabled by default), r=jhirsch
Differential Revision: https://phabricator.services.mozilla.com/D187779
This commit is contained in:
Родитель
f8cb048a49
Коммит
5736aa0cd2
|
@ -2052,9 +2052,7 @@ var gBrowserInit = {
|
|||
|
||||
CaptivePortalWatcher.delayedStartup();
|
||||
|
||||
if (AppConstants.NIGHTLY_BUILD) {
|
||||
ShoppingSidebarManager.init();
|
||||
}
|
||||
ShoppingSidebarManager.init();
|
||||
|
||||
SessionStore.promiseAllWindowsRestored.then(() => {
|
||||
this._schedulePerWindowIdleTasks();
|
||||
|
@ -2475,9 +2473,7 @@ var gBrowserInit = {
|
|||
|
||||
FirefoxViewHandler.uninit();
|
||||
|
||||
if (AppConstants.NIGHTLY_BUILD) {
|
||||
ShoppingSidebarManager.uninit();
|
||||
}
|
||||
ShoppingSidebarManager.uninit();
|
||||
|
||||
// Now either cancel delayedStartup, or clean up the services initialized from
|
||||
// it.
|
||||
|
@ -5885,9 +5881,7 @@ var TabsProgressListener = {
|
|||
|
||||
// Some shops use pushState to move between individual products, so
|
||||
// the shopping code needs to be told about all of these.
|
||||
if (AppConstants.NIGHTLY_BUILD) {
|
||||
ShoppingSidebarManager.onLocationChange(aBrowser, aLocationURI, aFlags);
|
||||
}
|
||||
ShoppingSidebarManager.onLocationChange(aBrowser, aLocationURI, aFlags);
|
||||
|
||||
// Filter out location changes caused by anchor navigation
|
||||
// or history.push/pop/replaceState.
|
||||
|
|
|
@ -87,10 +87,8 @@
|
|||
<!-- Untranslated FTL files -->
|
||||
<link rel="localization" href="preview/enUS-searchFeatures.ftl" />
|
||||
<link rel="localization" href="preview/interventions.ftl" />
|
||||
#ifdef NIGHTLY_BUILD
|
||||
<link rel="localization" href="browser/shopping.ftl"/>
|
||||
<link rel="localization" href="preview/shopping.ftl"/>
|
||||
#endif
|
||||
|
||||
<title data-l10n-id="browser-main-window-title"></title>
|
||||
|
||||
|
@ -119,9 +117,7 @@
|
|||
Services.scriptloader.loadSubScript("chrome://browser/content/places/places-menupopup.js", this);
|
||||
Services.scriptloader.loadSubScript("chrome://browser/content/search/autocomplete-popup.js", this);
|
||||
Services.scriptloader.loadSubScript("chrome://browser/content/search/searchbar.js", this);
|
||||
if (AppConstants.NIGHTLY_BUILD) {
|
||||
Services.scriptloader.loadSubScript("chrome://browser/content/shopping/shopping-sidebar.js", this);
|
||||
}
|
||||
Services.scriptloader.loadSubScript("chrome://browser/content/shopping/shopping-sidebar.js", this);
|
||||
|
||||
window.onload = gBrowserInit.onLoad.bind(gBrowserInit);
|
||||
window.onunload = gBrowserInit.onUnload.bind(gBrowserInit);
|
||||
|
|
|
@ -377,7 +377,6 @@
|
|||
<image class="urlbar-icon" id="translations-button-circle-arrows" />
|
||||
<html:span id="translations-button-locale" aria-hidden="true" />
|
||||
</hbox>
|
||||
#ifdef NIGHTLY_BUILD
|
||||
<hbox id="shopping-sidebar-button"
|
||||
class="urlbar-page-action"
|
||||
role="button"
|
||||
|
@ -387,7 +386,6 @@
|
|||
<image id="shopping-sidebar-button-icon"
|
||||
class="urlbar-icon"/>
|
||||
</hbox>
|
||||
#endif
|
||||
<toolbarbutton id="urlbar-zoom-button"
|
||||
onclick="FullZoom.resetFromURLBar(event);"
|
||||
tooltip="dynamic-shortcut-tooltip"
|
||||
|
|
|
@ -88,12 +88,6 @@ if (AppConstants.MOZ_BACKGROUNDTASKS) {
|
|||
gExceptionPaths.push("resource://app/modules/backgroundtasks/");
|
||||
}
|
||||
|
||||
// Temporary allowlist for shopping - we'll reference this soon.
|
||||
if (AppConstants.NIGHTLY_BUILD) {
|
||||
gExceptionPaths.push("chrome://browser/content/shopping/shopping.html");
|
||||
gExceptionPaths.push("chrome://global/content/shopping/ShoppingProduct.mjs");
|
||||
}
|
||||
|
||||
if (AppConstants.NIGHTLY_BUILD) {
|
||||
// This is nightly-only debug tool.
|
||||
gExceptionPaths.push(
|
||||
|
|
|
@ -2065,11 +2065,7 @@ BrowserGlue.prototype = {
|
|||
() => lazy.NewTabUtils.uninit(),
|
||||
() => lazy.Normandy.uninit(),
|
||||
() => lazy.RFPHelper.uninit(),
|
||||
() => {
|
||||
if (AppConstants.NIGHTLY_BUILD) {
|
||||
lazy.ShoppingUtils.uninit();
|
||||
}
|
||||
},
|
||||
() => lazy.ShoppingUtils.uninit(),
|
||||
() => lazy.ASRouterNewTabHook.destroy(),
|
||||
() => {
|
||||
if (AppConstants.MOZ_UPDATER) {
|
||||
|
@ -2982,7 +2978,6 @@ BrowserGlue.prototype = {
|
|||
|
||||
{
|
||||
name: "ShoppingUtils.init",
|
||||
condition: AppConstants.NIGHTLY_BUILD,
|
||||
task: () => {
|
||||
lazy.ShoppingUtils.init();
|
||||
},
|
||||
|
|
|
@ -95,14 +95,12 @@ static const RedirEntry kRedirMap[] = {
|
|||
{"sessionrestore", "chrome://browser/content/aboutSessionRestore.xhtml",
|
||||
nsIAboutModule::ALLOW_SCRIPT | nsIAboutModule::HIDE_FROM_ABOUTABOUT |
|
||||
nsIAboutModule::IS_SECURE_CHROME_UI},
|
||||
#ifdef NIGHTLY_BUILD
|
||||
{"shoppingsidebar", "chrome://browser/content/shopping/shopping.html",
|
||||
nsIAboutModule::URI_MUST_LOAD_IN_CHILD |
|
||||
nsIAboutModule::URI_CAN_LOAD_IN_PRIVILEGEDABOUT_PROCESS |
|
||||
nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT |
|
||||
nsIAboutModule::ALLOW_SCRIPT | nsIAboutModule::HIDE_FROM_ABOUTABOUT |
|
||||
nsIAboutModule::IS_SECURE_CHROME_UI},
|
||||
#endif
|
||||
{"tabcrashed", "chrome://browser/content/aboutTabCrashed.xhtml",
|
||||
nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT |
|
||||
nsIAboutModule::ALLOW_SCRIPT | nsIAboutModule::HIDE_FROM_ABOUTABOUT},
|
||||
|
|
|
@ -31,15 +31,13 @@ pages = [
|
|||
'rights',
|
||||
'robots',
|
||||
'sessionrestore',
|
||||
'shoppingsidebar',
|
||||
'tabcrashed',
|
||||
'unloads',
|
||||
'welcome',
|
||||
'welcomeback',
|
||||
]
|
||||
|
||||
if buildconfig.substs.get('NIGHTLY_BUILD'):
|
||||
pages += ['shoppingsidebar']
|
||||
|
||||
Classes = [
|
||||
{
|
||||
'cid': '{7e4bb6ad-2fc4-4dc6-89ef-23e8e5ccf980}',
|
||||
|
|
|
@ -55,6 +55,7 @@ DIRS += [
|
|||
"search",
|
||||
"sessionstore",
|
||||
"shell",
|
||||
"shopping",
|
||||
"syncedtabs",
|
||||
"tabunloader",
|
||||
"textrecognition",
|
||||
|
@ -65,9 +66,6 @@ DIRS += [
|
|||
|
||||
DIRS += ["build"]
|
||||
|
||||
if CONFIG["NIGHTLY_BUILD"]:
|
||||
DIRS += ["shopping"]
|
||||
|
||||
|
||||
if CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa":
|
||||
DIRS += ["touchbar"]
|
||||
|
|
|
@ -12,9 +12,7 @@
|
|||
preview/protections.ftl (../components/protections/content/protections.ftl)
|
||||
preview/interventions.ftl (../components/urlbar/content/interventions.ftl)
|
||||
preview/enUS-searchFeatures.ftl (../components/urlbar/content/enUS-searchFeatures.ftl)
|
||||
#ifdef NIGHTLY_BUILD
|
||||
preview/shopping.ftl (../components/shopping/content/shopping.ftl)
|
||||
#endif
|
||||
browser (%browser/**/*.ftl)
|
||||
|
||||
@AB_CD@.jar:
|
||||
|
|
|
@ -65,6 +65,7 @@ DIRS += [
|
|||
"search",
|
||||
"sessionstore",
|
||||
"shell",
|
||||
"shopping",
|
||||
"startup",
|
||||
"statusfilter",
|
||||
"telemetry",
|
||||
|
@ -110,9 +111,6 @@ if CONFIG["MOZ_UPDATE_AGENT"]:
|
|||
|
||||
DIRS += ["build"]
|
||||
|
||||
if CONFIG["NIGHTLY_BUILD"]:
|
||||
DIRS += ["shopping"]
|
||||
|
||||
if CONFIG["MOZ_WIDGET_TOOLKIT"] == "windows":
|
||||
DIRS += ["aboutthirdparty", "aboutwindowsmessages", "gfx"]
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче