зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1541508 - Use Services.env in layout/ r=layout-reviewers,emilio
Differential Revision: https://phabricator.services.mozilla.com/D160140
This commit is contained in:
Родитель
c8551a7c7d
Коммит
267a101012
|
@ -341,10 +341,7 @@ function OnLDBLoad() {
|
|||
|
||||
if (gArgs.profile) {
|
||||
if (Services.profiler) {
|
||||
let env = Cc["@mozilla.org/process/environment;1"].getService(
|
||||
Ci.nsIEnvironment
|
||||
);
|
||||
if (!env.exists("MOZ_PROFILER_SYMBOLICATE")) {
|
||||
if (!Services.env.exists("MOZ_PROFILER_SYMBOLICATE")) {
|
||||
dump(
|
||||
"Warning: MOZ_PROFILER_SYMBOLICATE environment variable not set; " +
|
||||
"profile will not be symbolicated.\n"
|
||||
|
|
|
@ -472,8 +472,6 @@ function BuildConditionSandbox(aURL) {
|
|||
sandbox.isCoverageBuild = g.isCoverageBuild;
|
||||
var prefs = Cc["@mozilla.org/preferences-service;1"].
|
||||
getService(Ci.nsIPrefBranch);
|
||||
var env = Cc["@mozilla.org/process/environment;1"].
|
||||
getService(Ci.nsIEnvironment);
|
||||
|
||||
sandbox.xulRuntime = Cu.cloneInto({widgetToolkit: xr.widgetToolkit, OS: xr.OS, XPCOMABI: xr.XPCOMABI}, sandbox);
|
||||
|
||||
|
|
|
@ -8,7 +8,6 @@ const XHTML_NS = "http://www.w3.org/1999/xhtml";
|
|||
|
||||
const DEBUG_CONTRACTID = "@mozilla.org/xpcom/debug;1";
|
||||
const PRINTSETTINGS_CONTRACTID = "@mozilla.org/gfx/printsettings-service;1";
|
||||
const ENVIRONMENT_CONTRACTID = "@mozilla.org/process/environment;1";
|
||||
const NS_OBSERVER_SERVICE_CONTRACTID = "@mozilla.org/observer-service;1";
|
||||
const NS_GFXINFO_CONTRACTID = "@mozilla.org/gfx/info;1";
|
||||
const IO_SERVICE_CONTRACTID = "@mozilla.org/network/io-service;1"
|
||||
|
@ -108,8 +107,7 @@ function OnInitialLoad()
|
|||
if (gDebug.isDebugBuild) {
|
||||
gAssertionCount = gDebug.assertionCount;
|
||||
}
|
||||
var env = Cc[ENVIRONMENT_CONTRACTID].getService(Ci.nsIEnvironment);
|
||||
gVerbose = !!env.get("MOZ_REFTEST_VERBOSE");
|
||||
gVerbose = !!Services.env.get("MOZ_REFTEST_VERBOSE");
|
||||
|
||||
RegisterMessageListeners();
|
||||
|
||||
|
|
|
@ -186,9 +186,6 @@ function OnRefTestLoad(win)
|
|||
g.pendingCrashDumpDir.append("Crash Reports");
|
||||
g.pendingCrashDumpDir.append("pending");
|
||||
|
||||
var env = Cc["@mozilla.org/process/environment;1"].
|
||||
getService(Ci.nsIEnvironment);
|
||||
|
||||
g.browserIsRemote = Services.appinfo.browserTabsRemoteAutostart;
|
||||
g.browserIsFission = Services.appinfo.fissionAutostart;
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче