[Basilisk] Issue MoonchildProductions/UXP#1390 - Remove application support for the Presentation API

This commit is contained in:
Matt A. Tobin 2020-02-06 14:03:23 -05:00 committed by Roy Tam
commit bb4519ea4f
10 changed files with 1 additions and 298 deletions

View file

@ -56,7 +56,6 @@ XPCOMUtils.defineLazyServiceGetter(this, "AlertsService", "@mozilla.org/alerts-s
["RemotePrompt", "resource:///modules/RemotePrompt.jsm"],
["SessionStore", "resource:///modules/sessionstore/SessionStore.jsm"],
["ShellService", "resource:///modules/ShellService.jsm"],
["SimpleServiceDiscovery", "resource://gre/modules/SimpleServiceDiscovery.jsm"],
["TabCrashHandler", "resource:///modules/ContentCrashHandlers.jsm"],
["Task", "resource://gre/modules/Task.jsm"],
["URLBarZoom", "resource:///modules/URLBarZoom.jsm"],
@ -1017,32 +1016,8 @@ BrowserGlue.prototype = {
}
},
_initServiceDiscovery: function () {
if (!Services.prefs.getBoolPref("browser.casting.enabled")) {
return;
}
var rokuDevice = {
id: "roku:ecp",
target: "roku:ecp",
factory: function(aService) {
Cu.import("resource://gre/modules/RokuApp.jsm");
return new RokuApp(aService);
},
types: ["video/mp4"],
extensions: ["mp4"]
};
// Register targets
SimpleServiceDiscovery.registerDevice(rokuDevice);
// Search for devices continuously every 120 seconds
SimpleServiceDiscovery.search(120 * 1000);
},
// All initial windows have opened.
_onWindowsRestored: function BG__onWindowsRestored() {
this._initServiceDiscovery();
// Show update notification, if needed.
if (Services.prefs.prefHasUserValue("app.update.postupdate"))
this._showUpdateNotification();