Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/TurtleArt
diff options
context:
space:
mode:
authorWalter Bender <walter.bender@gmail.com>2012-02-16 22:16:48 (GMT)
committer Walter Bender <walter.bender@gmail.com>2012-02-16 22:16:48 (GMT)
commit9a44aa9dcb587dc70ee6e30d21b162f8ca02c59e (patch)
tree6da2c838532b66b45ff666c644d7fe4090f3283a /TurtleArt
parent04b3f58fc6ef3a3075d13fd2b9e06dcd6c44a0d9 (diff)
more debugging of boolean compare block docking/expanding
Diffstat (limited to 'TurtleArt')
-rw-r--r--TurtleArt/tawindow.py15
1 files changed, 4 insertions, 11 deletions
diff --git a/TurtleArt/tawindow.py b/TurtleArt/tawindow.py
index e1de162..9441ad8 100644
--- a/TurtleArt/tawindow.py
+++ b/TurtleArt/tawindow.py
@@ -2028,7 +2028,8 @@ class TurtleArtWindow():
for gblk in find_group(blk):
if gblk not in group:
gblk.spr.move_relative((0, dy * blk.scale))
- if blk.name in block_styles['compare-style']:
+ if blk.name in block_styles['compare-style'] or \
+ blk.name in block_styles['compare-porch-style']:
for gblk in find_group(blk):
gblk.spr.move_relative((0, -dy * blk.scale))
@@ -2065,7 +2066,8 @@ class TurtleArtWindow():
for gblk in find_group(blk):
if gblk not in group:
gblk.spr.move_relative((0, dy * blk.scale))
- if blk.name in block_styles['compare-style']:
+ if blk.name in block_styles['compare-style'] or \
+ blk.name in block_styles['compare-porch-style']:
for gblk in find_group(blk):
gblk.spr.move_relative((0, -dy * blk.scale))
else:
@@ -2194,12 +2196,6 @@ class TurtleArtWindow():
else:
dy = 20 + selected_block.ey - best_destination.ey
best_destination.expand_in_y(dy)
- if best_destination.name in block_styles[
- 'compare-porch-style']:
- offset = -dy * best_destination.scale
- best_destination.spr.move_relative((0, offset))
- for blk in self.drag_group:
- blk.spr.move_relative((0, offset))
else:
if best_destination.ey > 0:
dy = best_destination.reset_y()
@@ -2232,9 +2228,6 @@ class TurtleArtWindow():
dy = blk2.reset_y()
if dy != 0:
self._expand_expandable(blk2, blk, dy)
- if blk2.name in block_styles[
- 'compare-porch-style']:
- blk2.spr.move_relative((0, -dy * blk2.scale))
self._cascade_expandable(blk2)
grow_stack_arm(find_sandwich_top(blk2))