diff options
author | Nivesh Rajbhandari | 2012-05-07 11:18:11 -0700 |
---|---|---|
committer | Nivesh Rajbhandari | 2012-05-07 11:18:11 -0700 |
commit | e377a8dc0b0e34905782ed867acb5fe725ae0131 (patch) | |
tree | 6931311aabd7a4e366df195a168d437f1d0d8465 /js/mediators | |
parent | 8be6e94b57f4bd6e28754a6113b4d6a401365e13 (diff) | |
parent | 526e423e4a2734c2b139af23911e912452a4443f (diff) | |
download | ninja-e377a8dc0b0e34905782ed867acb5fe725ae0131.tar.gz |
Merge branch 'refs/heads/ninja-internal' into WebGLFixes
Diffstat (limited to 'js/mediators')
-rwxr-xr-x | js/mediators/drag-drop-mediator.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/js/mediators/drag-drop-mediator.js b/js/mediators/drag-drop-mediator.js index b0aba5b6..59086ef6 100755 --- a/js/mediators/drag-drop-mediator.js +++ b/js/mediators/drag-drop-mediator.js | |||
@@ -114,11 +114,13 @@ exports.DragDropMediator = Montage.create(Component, { | |||
114 | var self = this; | 114 | var self = this; |
115 | // | 115 | // |
116 | if (e.currentTarget.fileType.indexOf('svg') !== -1) { | 116 | if (e.currentTarget.fileType.indexOf('svg') !== -1) { |
117 | element = NJUtils.makeNJElement('embed', 'SVG', 'block');//TODO: Verify this is proper | 117 | element = NJUtils.make('embed', null, this.application.ninja.currentDocument);//TODO: Verify this is proper |
118 | NJUtils.createModelWithSelection(element, "SVG"); | ||
118 | element.type = 'image/svg+xml'; | 119 | element.type = 'image/svg+xml'; |
119 | element.src = url+'/'+fileName; | 120 | element.src = url+'/'+fileName; |
120 | } else { | 121 | } else { |
121 | element = NJUtils.makeNJElement('image', 'image', 'image'); | 122 | element = NJUtils.make('image', null, this.application.ninja.currentDocument); |
123 | NJUtils.createModel(element); | ||
122 | element.src = url+'/'+fileName; | 124 | element.src = url+'/'+fileName; |
123 | } | 125 | } |
124 | //Adding element once it is loaded | 126 | //Adding element once it is loaded |