Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[embedlite-components] Remove XULAppInfo from EmbedLiteGlobalHelper. …
…Contributes to JB#35001

We should be using EmbedLiteXulAppInfo instead of this that is
also registered. This shadows the EmbedLiteXulAppInfo. Thus, breaking e.g.
UserAgentUpdates.jsm to see wrong XULAppInfo when parsing
general.useragent.updates.url preference.
  • Loading branch information
rainemak committed May 12, 2016
1 parent e1809cc commit e8c7886
Showing 1 changed file with 0 additions and 33 deletions.
33 changes: 0 additions & 33 deletions jscomps/EmbedLiteGlobalHelper.js
Expand Up @@ -12,38 +12,6 @@ Components.utils.import("resource://gre/modules/LoginManagerParent.jsm");

// Common helper service

function InitializeXulAppInfo()
{
let XULAppInfo = {
vendor: "Mozilla",
name: "Firefox",
ID: "embedliteBrowser@embed.mozilla.org",
version: "23.0",
appBuildID: "20130329080257",
platformVersion: "23.0",
platformBuildID: "20130329080257",
inSafeMode: false,
logConsoleErrors: true,
OS: "Linux",
XPCOMABI: "noarch",
QueryInterface: XPCOMUtils.generateQI([Ci.nsIXULAppInfo, Ci.nsIXULRuntime]),
invalidateCachesOnRestart: function invalidateCachesOnRestart() { }
};

let XULAppInfoFactory = {
createInstance: function (outer, iid) {
if (outer != null)
throw Cr.NS_ERROR_NO_AGGREGATION;
return XULAppInfo.QueryInterface(iid);
}
};

let registrar = Components.manager.QueryInterface(Ci.nsIComponentRegistrar);
registrar.registerFactory(Components.ID("{0aba3008-9ad4-11e2-a327-cb2a226fec9f}"),
"XULAppInfo", "@mozilla.org/xre/app-info;1",
XULAppInfoFactory);
}

function EmbedLiteGlobalHelper()
{
}
Expand All @@ -55,7 +23,6 @@ EmbedLiteGlobalHelper.prototype = {
switch(aTopic) {
// Engine DownloadManager notifications
case "app-startup": {
InitializeXulAppInfo();
dump("EmbedLiteGlobalHelper app-startup\n");
Services.obs.addObserver(this, "invalidformsubmit", false);
Services.obs.addObserver(this, "xpcom-shutdown", false);
Expand Down

0 comments on commit e8c7886

Please sign in to comment.