summaryrefslogtreecommitdiff
path: root/gui.js
diff options
context:
space:
mode:
authorjmoenig <jens@moenig.org>2013-04-02 18:18:19 +0200
committerjmoenig <jens@moenig.org>2013-04-02 18:18:19 +0200
commit895ab6ddeb93938a75e779d9b3c0344330472933 (patch)
tree75440a1ebd19e5e9e92296d98b51b0264c83f2c0 /gui.js
parent84fd877fa483d986a9651b7d5555455cce978cae (diff)
downloadsnap-895ab6ddeb93938a75e779d9b3c0344330472933.tar.gz
snap-895ab6ddeb93938a75e779d9b3c0344330472933.zip
Anchored Comments Enhancements
* the Block Editor now allows anchored comments, * duplicating a block / script / sprite now also duplicates anchored comments, * deleting a block / script now also deletes anchored comments
Diffstat (limited to 'gui.js')
-rw-r--r--gui.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/gui.js b/gui.js
index 5642bde..d051dc1 100644
--- a/gui.js
+++ b/gui.js
@@ -4418,6 +4418,9 @@ SpriteIconMorph.prototype.copyStack = function (block) {
dup.setPosition(new Point(this.object.scripts.left() + 20, y + 20));
this.object.scripts.add(dup);
+ dup.allComments().forEach(function (comment) {
+ comment.align(dup);
+ });
this.object.scripts.adjustBounds();
// delete all custom blocks pointing to local definitions