mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-27 20:25:44 +00:00
61afcb67fd
Differential Revision: https://phabricator.services.mozilla.com/D18469 --HG-- rename : devtools/startup/aboutdebugging-new-registration.js => devtools/startup/AboutDebuggingNewRegistration.jsm rename : devtools/startup/aboutdebugging-registration.js => devtools/startup/AboutDebuggingRegistration.jsm rename : devtools/startup/aboutdevtoolstoolbox-registration.js => devtools/startup/AboutDevToolsToolboxRegistration.jsm rename : devtools/startup/devtools-startup.js => devtools/startup/DevToolsStartup.jsm rename : devtools/startup/aboutdevtools/aboutdevtools-registration.js => devtools/startup/aboutdevtools/AboutDevToolsRegistration.jsm extra : source : de0b9993bd5dceae296dfe863ea2455d15e2f6f1
41 lines
1.3 KiB
JavaScript
41 lines
1.3 KiB
JavaScript
/* 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";
|
|
|
|
// This component is only registered and packaged for local and nightly builds in order to
|
|
// open the new about:debugging when going to about:debugging-new, without having to flip
|
|
// the preference. This allows running both versions of about:debugging side by side to
|
|
// compare them.
|
|
const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
|
|
|
const { nsIAboutModule } = Ci;
|
|
|
|
function AboutDebuggingNew() {}
|
|
|
|
AboutDebuggingNew.prototype = {
|
|
classDescription: "about:debugging-new",
|
|
classID: Components.ID("610e4e26-26bd-4a7d-aebc-69211d5a3be0"),
|
|
contractID: "@mozilla.org/network/protocol/about;1?what=debugging-new",
|
|
|
|
QueryInterface: ChromeUtils.generateQI([nsIAboutModule]),
|
|
|
|
newChannel: function(_, loadInfo) {
|
|
const uri = "chrome://devtools/content/aboutdebugging-new/index.html";
|
|
|
|
const chan = Services.io.newChannelFromURIWithLoadInfo(
|
|
Services.io.newURI(uri),
|
|
loadInfo
|
|
);
|
|
chan.owner = Services.scriptSecurityManager.getSystemPrincipal();
|
|
return chan;
|
|
},
|
|
|
|
getURIFlags: function(uri) {
|
|
return nsIAboutModule.ALLOW_SCRIPT;
|
|
},
|
|
};
|
|
|
|
var EXPORTED_SYMBOLS = ["AboutDebuggingNew"];
|