diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-09-13 15:38:20 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-09-13 15:40:11 +0300 |
commit | 76e7c039ec501e64f55b293a17aee1968cdb7aeb (patch) | |
tree | ee4cf628684b91f837d1122f20feed4976b65d13 /release/scripts/startup/bl_operators/object_align.py | |
parent | 43858c4197d07ef179d54d77501056cdcbf26546 (diff) |
Fix T52140: Align objects centers using origin for text
The issue was caused by operator redo which frees all object's evaluated data,
including bounding box. This bounding box can not be reconstructed properly
without full curve evaluation (need to at least convert font to nurbs, which is
not cheap already).
Diffstat (limited to 'release/scripts/startup/bl_operators/object_align.py')
-rw-r--r-- | release/scripts/startup/bl_operators/object_align.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/release/scripts/startup/bl_operators/object_align.py b/release/scripts/startup/bl_operators/object_align.py index 1539ffb3545..b7d3866989d 100644 --- a/release/scripts/startup/bl_operators/object_align.py +++ b/release/scripts/startup/bl_operators/object_align.py @@ -131,6 +131,11 @@ def align_objects(context, cursor = (space if space and space.type == 'VIEW_3D' else scene).cursor_location + # We are accessing runtime data such as evaluated bounding box, so we need to + # be sure it is properly updated and valid (bounding box might be lost on operator + # redo). + scene.update() + Left_Front_Up_SEL = [0.0, 0.0, 0.0] Right_Back_Down_SEL = [0.0, 0.0, 0.0] |