Bug 787619 - Prevent clicks on the click-to-play placeholder triggering other handlers. r=jaws

This commit is contained in:
Georg Fritzsche 2012-10-19 15:11:04 +02:00
parent 3af429c4b8
commit 92d8ff57a2

View File

@ -326,8 +326,11 @@ var gPluginHandler = {
overlay.addEventListener("click", function(aEvent) {
// Have to check that the target is not the link to update the plugin
if (!(aEvent.originalTarget instanceof HTMLAnchorElement) &&
aEvent.button == 0 && aEvent.isTrusted)
aEvent.button == 0 && aEvent.isTrusted) {
gPluginHandler.activateSinglePlugin(aEvent.target.ownerDocument.defaultView.top, aPlugin);
aEvent.stopPropagation();
aEvent.preventDefault();
}
}, true);
}