summaryrefslogtreecommitdiff
path: root/gui.js
diff options
context:
space:
mode:
authorjmoenig <jens@moenig.org>2014-07-18 15:27:28 +0200
committerjmoenig <jens@moenig.org>2014-07-18 15:27:28 +0200
commit0e02a5ff6021bf6c5a86909b54dfdce50e1e478e (patch)
tree0e44ef33594ab6ecfa6999237348a165f73b58fc /gui.js
parent7328bfb034dbb2c329fcff7d63e5b34bc7963cd3 (diff)
downloadsnap-yow-0e02a5ff6021bf6c5a86909b54dfdce50e1e478e.tar.gz
snap-yow-0e02a5ff6021bf6c5a86909b54dfdce50e1e478e.zip
ensure unique costume names when copying costumes via d&d
Diffstat (limited to 'gui.js')
-rw-r--r--gui.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/gui.js b/gui.js
index 5bccd6d..6770465 100644
--- a/gui.js
+++ b/gui.js
@@ -5374,6 +5374,7 @@ SpriteIconMorph.prototype.copyStack = function (block) {
SpriteIconMorph.prototype.copyCostume = function (costume) {
var dup = costume.copy();
+ dup.name = this.object.newCostumeName(dup.name);
this.object.addCostume(dup);
this.object.wearCostume(dup);
};