aboutsummaryrefslogtreecommitdiff
path: root/js/mediators/drag-drop-mediator.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/mediators/drag-drop-mediator.js')
-rwxr-xr-xjs/mediators/drag-drop-mediator.js22
1 files changed, 11 insertions, 11 deletions
diff --git a/js/mediators/drag-drop-mediator.js b/js/mediators/drag-drop-mediator.js
index 7669dcfc..f23ec34c 100755
--- a/js/mediators/drag-drop-mediator.js
+++ b/js/mediators/drag-drop-mediator.js
@@ -80,8 +80,8 @@ exports.DragDropMediator = Montage.create(Component, {
80 80
81 handleDropEvent: { 81 handleDropEvent: {
82 value: function(e){ 82 value: function(e){
83 // 83 //
84 var i, files = e.dataTransfer.files, position = {x: e.offsetX, y: e.offsetY}, self = this; 84 var i, files = e.dataTransfer.files, position = {x: e.offsetX, y: e.offsetY}, self = this;
85 85
86 var xferString = e.dataTransfer.getData("text/plain"); 86 var xferString = e.dataTransfer.getData("text/plain");
87 if(xferString) { 87 if(xferString) {
@@ -93,17 +93,17 @@ exports.DragDropMediator = Montage.create(Component, {
93 } 93 }
94 } 94 }
95 } 95 }
96 // 96 //
97 for (i=0; files[i]; i++) { 97 for (i=0; files[i]; i++) {
98 if (files[i].type.indexOf('image') !== -1) { 98 if (files[i].type.indexOf('image') !== -1) {
99 this.application.ninja.ioMediator.createFileFromBinary(files[i], {"addFileToStage" : self.addImageElement.bind(self), "position": position}); 99 this.application.ninja.ioMediator.createFileFromBinary(files[i], {"addFileToStage" : self.addImageElement.bind(self), "position": position});
100 100
101 } else { 101 } else {
102 //TODO: NOT AN IMAGE, HANDLE SPECIAL CASE 102 //TODO: NOT AN IMAGE, HANDLE SPECIAL CASE
103 } 103 }
104 } 104 }
105 //Not sure why return value should be, seemed as false to work 105 //Not sure why return value should be, seemed as false to work
106 return false; 106 return false;
107 } 107 }
108 }, 108 },
109 109