Files
roytam1 be13290522 import changes from `dev' branch of rmottola/Arctic-Fox:
- Bug 847287 patch 1 - Add additional tests. r=birtles (10f885ee6)
- Bug 847287 patch 2 - Add flag for CSS properties that can be animated on the compositor. r=birtles (859fae81c)
- Bug 847287 patch 3 - Add assertions about consistency of the flags for animating on the compositor. r=birtles (bd7565728)
- Bug 1144973 - Ensure that StringifySavedFrameStack puts its stack string in the cx's compartment. r=bz (546bef57a)
- Bug 1147670 - Remove duplicate IsMarked/IsAboutToBeFinalized for off-thread use; r=jonco (b460a96ca)
- Bug 674779 - Per-component CPU monitoring, low-level. r=blassey, r=jandem (040bdbad7)
- Bug 674779 - Per-component CPU monitoring, high-level. r=blassey, r=mossop (59af11234)
- Bug 674779 - PerformanceStatsService data is not monotonic (wallpaper). r=yoric (32cecadf9)
- Bug 674779 - Deactivating subtest of test_measure for Windows XP. r=yoric (08833731a)
- Bug 1039866 - Rip out a bunch of metro-only code. r=jimm,gavin,rstrong (8e0e04182)
- Bug 1024668 - Extract core logic of abouthealth.js into new WebIDL interface. r=bz,gps,wchen (52675144a)
- Bug 1046420 - Part 1: Make MozSelfSupport a Window property instead of a global property. r=bz,wchen (7d50f737d)
- goannaAppInfo -> geckoAppInfo for coherency with IDL (8f04e1cdd)
- Bug 1075160 - Support action: reset a pref to the default setting r=gfritzsche, r=bholley (d68725e18)
- Bug 1075157 - Support action: reset search. r=gfritzsche, r=florian, r=bholley (1c770639b)
- Bug 1149343 - Part 1: Unify prefs/blacklist for hardware acceleration video decoding. r=cpearce (6380c6d16)
- Bug 1158430 - A small construct to allow only sending errors and warnings once per statement. r=botond (219130127)
- Bug 1162530 - Part 1: Add versioning to graphics blocklist. r=jmuizelaar (7f344653c)
- Bug 1162530 - Part 2: We were not allowing webrtc to be blocklisted in the downloadable scenario at all, expicitly look for unknown OS, and some minor white space changes. r=jrmuizel (45389ab14)
- Add an nsIGfxInfo function to query monitors. (bug 1175005 part 1, r=mattwoodrow) (22c4e7813)
- Add nsIGfxInfo::GetMonitor support for Windows. (bug 1175005 part 2, r=jimm) (307254292)
- Add nsIGfxInfo::ListMonitors support for OS X. (bug 1175005 part 3, r=mstange) (9b691de8d)
- Add nsIGfxInfo::GetMonitor support for Linux. (bug 1175005 part 4, r=nical) (a5cb518f2)
- Add APZ info to about:support. (bug 1146727, r=jrmuizel) (262235820)
- Bug 1146315 - Part 1: Create D3D media device on the ImageBridge thread. r=nical (3f930ad66)
- Bug 1146315 - Part 2: Release D3D11 YUV textures on the main thread. r=nical (9271a351f)
- Bug 1144900: Fix windows gfx out of memory assertion. r=Bas (73f7e963b)
- Bug 1147439: Report telemetry correctly for individual devices resetting. r=vladan (c19fb3322)
- Bug 1162587 - Part 1: Ensure consistent reporting of device reset until reinitialization. r=jrmuizel (eeb66799a)
- Bug 1162587 - Part 2: Abort painting a painted layer when a device reset has ocurred. r=jrmuizel (ae666232c)
2020-03-25 10:36:32 +08:00

79 lines
2.2 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";
const {classes: Cc, interfaces: Ci, utils: Cu} = Components;
Cu.import("resource://gre/modules/XPCOMUtils.jsm");
Cu.import("resource://gre/modules/Services.jsm");
const policy = Cc["@mozilla.org/datareporting/service;1"]
.getService(Ci.nsISupports)
.wrappedJSObject
.policy;
XPCOMUtils.defineLazyGetter(this, "reporter", () => {
return Cc["@mozilla.org/datareporting/service;1"]
.getService(Ci.nsISupports)
.wrappedJSObject
.healthReporter;
});
function MozSelfSupportInterface() {
}
MozSelfSupportInterface.prototype = {
classDescription: "MozSelfSupport",
classID: Components.ID("{d30aae8b-f352-4de3-b936-bb9d875df0bb}"),
contractID: "@mozilla.org/mozselfsupport;1",
QueryInterface: XPCOMUtils.generateQI([Ci.nsIDOMGlobalPropertyInitializer]),
_window: null,
init: function (window) {
this._window = window;
},
get healthReportDataSubmissionEnabled() {
return policy.healthReportUploadEnabled;
},
set healthReportDataSubmissionEnabled(enabled) {
let reason = "Self-support interface sent " +
(enabled ? "opt-in" : "opt-out") +
" command.";
policy.recordHealthReportUploadEnabled(enabled, reason);
},
getHealthReportPayload: function () {
return new this._window.Promise(function (aResolve, aReject) {
if (reporter) {
let resolvePayload = function () {
reporter.collectAndObtainJSONPayload(true).then(aResolve, aReject);
};
if (reporter.initialized) {
resolvePayload();
} else {
reporter.onInit().then(resolvePayload, aReject);
}
} else {
aReject(new Error("No reporter"));
}
}.bind(this));
},
resetPref: function(name) {
Services.prefs.clearUserPref(name);
},
resetSearchEngines: function() {
Services.search.restoreDefaultEngines();
Services.search.resetToOriginalDefaultEngine();
},
}
this.NSGetFactory = XPCOMUtils.generateNSGetFactory([MozSelfSupportInterface]);