gomita / firegestures

FireGestures, a Firefox extension.
http://www.xuldev.org/firegestures/
Other
128 stars 30 forks source link

Save Image Now not working #130

Closed aensaro closed 8 years ago

aensaro commented 8 years ago

I am using the latest version, with which this problem started to appear by the way. The error appears when trying to Save Image Now: TypeError: aInitiatingDocument is null

spider1313 commented 8 years ago

for now you can add in options a script for you gesture with the following code:


var srcNode = FireGestures.sourceNode; // get the link URL inside the node var linkURL = FireGestures.getLinkURL(srcNode);

if (srcNode.nodeType == Node.ELEMENT_NODE && srcNode instanceof Components.interfaces.nsIImageLoadingContent && srcNode.currentURI) { var docURL=srcNode.ownerDocument.location.href; var imageURL=srcNode.currentURI.spec; saveImageURL(imageURL, null, "SaveImageTitle", false, true, makeURI(docURL),document);

}

the problem is in the call of saveimageurl, now needs 7th param, document

gomita commented 8 years ago

Fixed: 7a58fd986f18acb4c43a52c9de1be9f4fb77486a