Skip to content
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.

Commit

Permalink
Merge pull request #465 from arv/set-drag-image
Browse files Browse the repository at this point in the history
Only add setDragImage if the browser supports it
  • Loading branch information
dfreedm committed Jul 7, 2014
2 parents 8972d7c + 4b7999c commit 964e80e
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/wrappers/DataTransfer.js
Expand Up @@ -17,8 +17,10 @@
var OriginalDataTransferSetDragImage =
OriginalDataTransfer.prototype.setDragImage;

OriginalDataTransfer.prototype.setDragImage = function(image, x, y) {
OriginalDataTransferSetDragImage.call(this, unwrap(image), x, y);
};
if (OriginalDataTransferSetDragImage) {
OriginalDataTransfer.prototype.setDragImage = function(image, x, y) {
OriginalDataTransferSetDragImage.call(this, unwrap(image), x, y);
};
}

})(window.ShadowDOMPolyfill);

0 comments on commit 964e80e

Please sign in to comment.