Sha256: d5c5d2e36a5e88e27246efaf2991f7a29a4bde1a1f4c4481ea4bf2544afdcf06
Contents?: true
Size: 1.72 KB
Versions: 4
Compression:
Stored size: 1.72 KB
Contents
{I" class:ETI"BundledAsset; FI"logical_path; TI"!rubber_ring/image_dragger.js; FI" pathname; TI"b/home/vagrant/development/rubber_ring/app/assets/javascripts/rubber_ring/image_dragger.coffee; FI"content_type; TI"application/javascript; TI" mtime; Tl+XÚxQI"length; TiüI"digest; TI"%7ea57e56409da3030f5c8591c868567a; FI"source; TI"ü(function() { this.ImageDragger = (function() { function ImageDragger(drag_selector, drop_selector) { var drag_item, drag_items, drop_image, _i, _len; drag_items = document.querySelectorAll(drag_selector); for (_i = 0, _len = drag_items.length; _i < _len; _i++) { drag_item = drag_items[_i]; addEvent(drag_item, "dragstart", function(event) { return event.dataTransfer.setData("src", $(this).attr("src")); }); } drop_image = document.querySelector(drop_selector); addEvent(drop_image, "dragover", this.cancel); addEvent(drop_image, "dragenter", this.cancel); addEvent(drop_image, "drop", function(e) { var pm; if (e.preventDefault) { e.preventDefault(); } if ($(this).attr("src") !== e.dataTransfer.getData("src")) { pm = new PersistenceManager(); this.src = e.dataTransfer.getData("src"); pm.save_image($(this)); } return false; }); } ImageDragger.prototype.cancel = function(e) { if (e.preventDefault && $(this).attr("src") !== e.dataTransfer.getData("src")) { e.preventDefault(); } return false; }; return ImageDragger; })(); }).call(this); ; TI"required_assets_digest; TI"%520afde3753ce7b42021fea63162fdbf; FI" _version; TI"%1e2632a10b8c877576b37720d5bf8883; F
Version data entries
4 entries across 2 versions & 1 rubygems