зеркало из https://github.com/mozilla/gecko-dev.git
bug 1175005: performance regression. backout_d9c8c1d14037
This commit is contained in:
Родитель
f5c8feb72b
Коммит
9249b50720
|
@ -1127,18 +1127,8 @@ EnvironmentCache.prototype = {
|
||||||
// again as part of bug 1154500.
|
// again as part of bug 1154500.
|
||||||
//DWriteVersion: getGfxField("DWriteVersion", null),
|
//DWriteVersion: getGfxField("DWriteVersion", null),
|
||||||
adapters: [],
|
adapters: [],
|
||||||
monitors: [],
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#if !defined(MOZ_WIDGET_GONK) && !defined(MOZ_WIDGET_ANDROID)
|
|
||||||
let gfxInfo = Cc["@mozilla.org/gfx/info;1"].getService(Ci.nsIGfxInfo);
|
|
||||||
try {
|
|
||||||
gfxData.monitors = gfxInfo.getMonitors();
|
|
||||||
} catch (e) {
|
|
||||||
this._log.error("nsIGfxInfo.getMonitors() caught error", e);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// GfxInfo does not yet expose a way to iterate through all the adapters.
|
// GfxInfo does not yet expose a way to iterate through all the adapters.
|
||||||
gfxData.adapters.push(getGfxAdapter(""));
|
gfxData.adapters.push(getGfxAdapter(""));
|
||||||
gfxData.adapters[0].GPUActive = true;
|
gfxData.adapters[0].GPUActive = true;
|
||||||
|
|
|
@ -133,18 +133,6 @@ Structure::
|
||||||
},
|
},
|
||||||
...
|
...
|
||||||
],
|
],
|
||||||
// Note: currently only added on Desktop. On Linux, only a single
|
|
||||||
// monitor is returned representing the entire virtual screen.
|
|
||||||
monitors: [
|
|
||||||
{
|
|
||||||
screenWidth: <number>, // screen width in pixels
|
|
||||||
screenHeight: <number>, // screen height in pixels
|
|
||||||
refreshRate: <number>, // refresh rate in hertz (present on Windows only)
|
|
||||||
pseudoDisplay: <bool>, // networked screen (present on Windows only)
|
|
||||||
scale: <number>, // backing scale factor (present on Mac only)
|
|
||||||
},
|
|
||||||
...
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
addons: {
|
addons: {
|
||||||
|
|
|
@ -416,20 +416,6 @@ function checkSystemSection(data) {
|
||||||
Assert.equal(typeof gfxData.adapters[0].GPUActive, "boolean");
|
Assert.equal(typeof gfxData.adapters[0].GPUActive, "boolean");
|
||||||
Assert.ok(gfxData.adapters[0].GPUActive, "The first GFX adapter must be active.");
|
Assert.ok(gfxData.adapters[0].GPUActive, "The first GFX adapter must be active.");
|
||||||
|
|
||||||
Assert.ok(Array.isArray(gfxData.monitors));
|
|
||||||
if (gIsWindows || gIsMac) {
|
|
||||||
Assert.ok(gfxData.monitors.length >= 1, "There is at least one monitor.");
|
|
||||||
Assert.equal(typeof gfxData.monitors[0].screenWidth, "number");
|
|
||||||
Assert.equal(typeof gfxData.monitors[0].screenHeight, "number");
|
|
||||||
if (gIsWindows) {
|
|
||||||
Assert.equal(typeof gfxData.monitors[0].refreshRate, "number");
|
|
||||||
Assert.equal(typeof gfxData.monitors[0].pseudoDisplay, "boolean");
|
|
||||||
}
|
|
||||||
if (gIsMac) {
|
|
||||||
Assert.equal(typeof gfxData.monitors[0].scale, "number");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
// If we've not got nsIGfxInfoDebug, then this will throw and stop us doing
|
// If we've not got nsIGfxInfoDebug, then this will throw and stop us doing
|
||||||
// this test.
|
// this test.
|
||||||
|
|
Загрузка…
Ссылка в новой задаче