From e5465309f80840308242d36dd24f957d65b9c2e1 Mon Sep 17 00:00:00 2001 From: oonuma ryouyu Date: Thu, 16 Jun 2016 02:26:00 -0700 Subject: [PATCH] save AboutGroup.js for decide by fx version. --- components/AboutGroup.js | 29 ++++++++++++++++++----------- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/components/AboutGroup.js b/components/AboutGroup.js index 65f830f5..a2a142c2 100644 --- a/components/AboutGroup.js +++ b/components/AboutGroup.js @@ -47,17 +47,24 @@ AboutGroup.prototype = { newChannel : function(aURI) { - //return Services.io.newChannel('chrome://treestyletab/content/group.xul', null, null); - return Services.io.newChannel2( - 'chrome://treestyletab/content/group.xul', - null, - null, - null, - Services.scriptSecurityManager.getSystemPrincipal(), - Services.scriptSecurityManager.getSystemPrincipal(), - Components.interfaces.nsILoadInfo.SEC_REQUIRE_SAME_ORIGIN_DATA_IS_BLOCKED, - Components.interfaces.nsIContentPolicy.TYPE_OTHER - ); + const version = Services.appinfo.platformVersion; + console.log("hello! this firefox version is"+version); + if(version){ + console.log("hello! this firefox newChannel"); + return Services.io.newChannel('chrome://treestyletab/content/group.xul', null, null); + }else{ + console.log("hello! this firefox newChannel"); + return Services.io.newChannel2( + 'chrome://treestyletab/content/group.xul', + null, + null, + null, + Services.scriptSecurityManager.getSystemPrincipal(), + Services.scriptSecurityManager.getSystemPrincipal(), + Components.interfaces.nsILoadInfo.SEC_REQUIRE_SAME_ORIGIN_DATA_IS_BLOCKED, + Components.interfaces.nsIContentPolicy.TYPE_OTHER + ); + } }, getURIFlags : function(aURI)