summaryrefslogtreecommitdiff
path: root/gui.js
diff options
context:
space:
mode:
authorjmoenig <jens@moenig.org>2013-06-28 20:42:28 +0200
committerjmoenig <jens@moenig.org>2013-06-28 20:42:28 +0200
commit09e3a296c25a73b4b4a21e1d0a2d9f6ce673f01f (patch)
tree46c0a7d75e5029c86ef6acf35e2064d6de1dfa39 /gui.js
parentb8c48040a26befd6a4670dbc89f5e91ef51210ea (diff)
downloadsnap-byow-09e3a296c25a73b4b4a21e1d0a2d9f6ce673f01f.tar.gz
snap-byow-09e3a296c25a73b4b4a21e1d0a2d9f6ce673f01f.zip
improved importing costumes
by dragging in pictures from other web pages, which now allows for dragging links to pictures as well
Diffstat (limited to 'gui.js')
-rw-r--r--gui.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/gui.js b/gui.js
index 4f4f94b..11cecf6 100644
--- a/gui.js
+++ b/gui.js
@@ -68,7 +68,7 @@ sb, CommentMorph, CommandBlockMorph*/
// Global stuff ////////////////////////////////////////////////////////
-modules.gui = '2013-June-26';
+modules.gui = '2013-June-28';
// Declarations
@@ -1477,7 +1477,10 @@ IDE_Morph.prototype.reactToWorldResize = function (rect) {
};
IDE_Morph.prototype.droppedImage = function (aCanvas, name) {
- var costume = new Costume(aCanvas, name.split('.')[0]); // up to period
+ var costume = new Costume(
+ aCanvas,
+ name ? name.split('.')[0] : '' // up to period
+ );
this.currentSprite.addCostume(costume);
this.currentSprite.wearCostume(costume);
this.spriteBar.tabBar.tabTo('costumes');