Bug 785190 - Add canActivatePlugin to reshowClickToPlayNotification. r=jaws
☠☠ backed out by 7058cad952ca ☠ ☠
authorYury <async.processingjs@yahoo.com>
Fri, 24 Aug 2012 16:18:17 -0400
changeset 105381 b3c861bd1e2fda67d732c0520c4c0eec997a7258
parent 105380 4e2788b485d4ee18379a678ac2271bb228ed08a1
child 105382 1bc0e4eac6e53c239afd2bc8416f543024d92b77
push id55
push usershu@rfrn.org
push dateThu, 30 Aug 2012 01:33:09 +0000
reviewersjaws
bugs785190
milestone17.0a1
Bug 785190 - Add canActivatePlugin to reshowClickToPlayNotification. r=jaws
browser/base/content/browser-plugins.js
--- a/browser/base/content/browser-plugins.js
+++ b/browser/base/content/browser-plugins.js
@@ -360,17 +360,17 @@ var gPluginHandler = {
     if (pluginsPermission == Ci.nsIPermissionManager.DENY_ACTION)
       return;
 
     let contentWindow = browser.contentWindow;
     let cwu = contentWindow.QueryInterface(Ci.nsIInterfaceRequestor)
                            .getInterface(Ci.nsIDOMWindowUtils);
     let pluginNeedsActivation = cwu.plugins.some(function(plugin) {
       let objLoadingContent = plugin.QueryInterface(Ci.nsIObjectLoadingContent);
-      return !objLoadingContent.activated;
+      return gPluginHandler.canActivatePlugin(objLoadingContent);
     });
     if (pluginNeedsActivation)
       gPluginHandler._showClickToPlayNotification(browser);
   },
 
   _showClickToPlayNotification: function PH_showClickToPlayNotification(aBrowser) {
     aBrowser._clickToPlayDoorhangerShown = true;
     let contentWindow = aBrowser.contentWindow;