1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-30 07:32:26 +01:00

Fix cross-compartment instanceof issues.

--HG--
extra : rebase_source : 9145412ce33e18bae5d889454fd1ff98c4067d09
This commit is contained in:
Kris Maglione
2013-08-01 21:35:23 -07:00
parent 81997f897f
commit b65dbd00ee
6 changed files with 26 additions and 19 deletions

View File

@@ -157,7 +157,7 @@ var MOW = Module("mow", {
dactyl.open(event.target.href, where);
};
if (event.target instanceof HTMLAnchorElement)
if (event.target instanceof Ci.nsIDOMHTMLAnchorElement)
switch (DOM.Event.stringify(event)) {
case "<LeftMouse>":
openLink(dactyl.CURRENT_TAB);
@@ -192,7 +192,7 @@ var MOW = Module("mow", {
popupshowing: function onPopupShowing(event) {
let menu = commandline.widgets.contextMenu;
let enabled = {
link: window.document.popupNode instanceof HTMLAnchorElement,
link: window.document.popupNode instanceof Ci.nsIDOMHTMLAnchorElement,
path: window.document.popupNode.hasAttribute("path"),
selection: !window.document.commandDispatcher.focusedWindow.getSelection().isCollapsed
};