зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1305777 - Remove RDM manager switch and pref. r=ochameau
This removes the switching based on the RDM.html pref and the pref itself. Some files in old RDM are updated for completeness, but they are about to be removed anyway. MozReview-Commit-ID: JnTC7ZF3UCC --HG-- extra : rebase_source : d591e04148d748c2659093295160adc6a3d2c445
This commit is contained in:
Родитель
b20d8b7cc0
Коммит
41503ce759
|
@ -27,7 +27,7 @@ loader.lazyGetter(this, "DomPanel", () => require("devtools/client/dom/dom-panel
|
|||
// Other dependencies
|
||||
loader.lazyRequireGetter(this, "CommandUtils", "devtools/client/shared/developer-toolbar", true);
|
||||
loader.lazyRequireGetter(this, "CommandState", "devtools/shared/gcli/command-state", true);
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsivedesign/responsivedesign");
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsive.html/manager", true);
|
||||
loader.lazyImporter(this, "ScratchpadManager", "resource://devtools/client/scratchpad/scratchpad-manager.jsm");
|
||||
|
||||
const {MultiLocalizationHelper} = require("devtools/shared/l10n");
|
||||
|
|
|
@ -25,7 +25,7 @@ loader.lazyRequireGetter(this, "DebuggerClient", "devtools/shared/client/main",
|
|||
loader.lazyRequireGetter(this, "BrowserMenus", "devtools/client/framework/browser-menus");
|
||||
loader.lazyRequireGetter(this, "appendStyleSheet", "devtools/client/shared/stylesheet-utils", true);
|
||||
loader.lazyRequireGetter(this, "DeveloperToolbar", "devtools/client/shared/developer-toolbar", true);
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsivedesign/responsivedesign");
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsive.html/manager", true);
|
||||
loader.lazyImporter(this, "BrowserToolboxProcess", "resource://devtools/client/framework/ToolboxProcess.jsm");
|
||||
loader.lazyImporter(this, "ScratchpadManager", "resource://devtools/client/scratchpad/scratchpad-manager.jsm");
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
loader.lazyRequireGetter(this, "gDevToolsBrowser", "devtools/client/framework/devtools-browser", true);
|
||||
loader.lazyRequireGetter(this, "CommandUtils", "devtools/client/shared/developer-toolbar", true);
|
||||
loader.lazyRequireGetter(this, "TargetFactory", "devtools/client/framework/target", true);
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsivedesign/responsivedesign");
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsive.html/manager", true);
|
||||
|
||||
loader.lazyImporter(this, "BrowserToolboxProcess", "resource://devtools/client/framework/ToolboxProcess.jsm");
|
||||
loader.lazyImporter(this, "ScratchpadManager", "resource://devtools/client/scratchpad/scratchpad-manager.jsm");
|
||||
|
|
|
@ -337,6 +337,3 @@ pref("devtools.editor.autocomplete", true);
|
|||
// opened developer tool. This allows us to ping telemetry just once per browser
|
||||
// version for each user.
|
||||
pref("devtools.telemetry.tools.opened.version", "{}");
|
||||
|
||||
// Enable the HTML responsive design mode for all channels.
|
||||
pref("devtools.responsive.html.enabled", true);
|
||||
|
|
|
@ -31,10 +31,6 @@ loader.lazyRequireGetter(this, "EmulationFront",
|
|||
/**
|
||||
* ResponsiveUIManager is the external API for the browser UI, etc. to use when
|
||||
* opening and closing the responsive UI.
|
||||
*
|
||||
* While the HTML UI is in an experimental stage, the older ResponsiveUIManager
|
||||
* from devtools/client/responsivedesign/responsivedesign.jsm delegates to this
|
||||
* object when the pref "devtools.responsive.html.enabled" is true.
|
||||
*/
|
||||
const ResponsiveUIManager = exports.ResponsiveUIManager = {
|
||||
activeTabs: new Map(),
|
||||
|
|
|
@ -51,19 +51,16 @@ flags.testing = true;
|
|||
Services.prefs.clearUserPref("devtools.responsive.html.displayedDeviceList");
|
||||
Services.prefs.setCharPref("devtools.devices.url",
|
||||
TEST_URI_ROOT + "devices.json");
|
||||
Services.prefs.setBoolPref("devtools.responsive.html.enabled", true);
|
||||
|
||||
registerCleanupFunction(() => {
|
||||
flags.testing = false;
|
||||
Services.prefs.clearUserPref("devtools.devices.url");
|
||||
Services.prefs.clearUserPref("devtools.responsive.html.enabled");
|
||||
Services.prefs.clearUserPref("devtools.responsive.html.displayedDeviceList");
|
||||
asyncStorage.removeItem("devtools.devices.url_cache");
|
||||
asyncStorage.removeItem("devtools.devices.local");
|
||||
});
|
||||
|
||||
// This depends on the "devtools.responsive.html.enabled" pref
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsivedesign/responsivedesign");
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsive.html/manager", true);
|
||||
|
||||
/**
|
||||
* Open responsive design mode for the given tab.
|
||||
|
|
|
@ -7,7 +7,6 @@ BROWSER_CHROME_MANIFESTS += ['test/browser.ini']
|
|||
DevToolsModules(
|
||||
'resize-commands.js',
|
||||
'responsivedesign-old.js',
|
||||
'responsivedesign.js',
|
||||
)
|
||||
|
||||
with Files('**'):
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
const { Cc, Ci, Cu } = require("chrome");
|
||||
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsivedesign/responsivedesign");
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsive.html/manager", true);
|
||||
|
||||
const BRAND_SHORT_NAME = Cc["@mozilla.org/intl/stringbundle;1"].
|
||||
getService(Ci.nsIStringBundleService).
|
||||
|
|
|
@ -1,22 +0,0 @@
|
|||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
"use strict";
|
||||
|
||||
const Services = require("Services");
|
||||
|
||||
const NEW_RDM_ENABLED = "devtools.responsive.html.enabled";
|
||||
|
||||
// If the new HTML RDM UI is enabled and e10s is enabled by default (e10s is required for
|
||||
// the new HTML RDM UI to function), delegate the ResponsiveUIManager API over to that
|
||||
// tool instead. Performing this delegation here allows us to contain the pref check to a
|
||||
// single place.
|
||||
if (Services.prefs.getBoolPref(NEW_RDM_ENABLED) &&
|
||||
Services.appinfo.browserTabsRemoteAutostart) {
|
||||
let { ResponsiveUIManager } = require("devtools/client/responsive.html/manager");
|
||||
module.exports = ResponsiveUIManager;
|
||||
} else {
|
||||
let { ResponsiveUIManager } = require("devtools/client/responsivedesign/responsivedesign-old");
|
||||
module.exports = ResponsiveUIManager;
|
||||
}
|
|
@ -27,7 +27,7 @@ registerCleanupFunction(() => {
|
|||
|
||||
SimpleTest.requestCompleteLog();
|
||||
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsivedesign/responsivedesign");
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsive.html/manager");
|
||||
|
||||
/**
|
||||
* Open the Responsive Design Mode
|
||||
|
|
|
@ -10,7 +10,7 @@ const TEST_URI = "data:text/html;charset=utf-8," +
|
|||
// opened we make use of setTimeout() to create tool active times.
|
||||
const TOOL_DELAY = 200;
|
||||
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsivedesign/responsivedesign");
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsive.html/manager", true);
|
||||
|
||||
add_task(function* () {
|
||||
yield addTab(TEST_URI);
|
||||
|
|
|
@ -31,7 +31,7 @@ const csscoverage = require("devtools/shared/fronts/csscoverage");
|
|||
const {console} = require("resource://gre/modules/Console.jsm");
|
||||
const {KeyCodes} = require("devtools/client/shared/keycodes");
|
||||
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsivedesign/responsivedesign");
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsive.html/manager", true);
|
||||
|
||||
const LOAD_ERROR = "error-load";
|
||||
const STYLE_EDITOR_TEMPLATE = "stylesheet";
|
||||
|
|
|
@ -16,7 +16,7 @@ registerCleanupFunction(() => {
|
|||
asyncStorage.removeItem("devtools.devices.url_cache");
|
||||
});
|
||||
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsivedesign/responsivedesign");
|
||||
loader.lazyRequireGetter(this, "ResponsiveUIManager", "devtools/client/responsive.html/manager", true);
|
||||
|
||||
const TESTCASE_URI = TEST_BASE_HTTPS + "media-rules.html";
|
||||
const responsiveModeToggleClass = ".media-responsive-mode-toggle";
|
||||
|
|
Загрузка…
Ссылка в новой задаче