Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLipu Fei <lipu.fei815@gmail.com>2019-04-24 12:04:31 +0300
committerLipu Fei <lipu.fei815@gmail.com>2019-04-24 12:04:33 +0300
commit3a195e9678513c8b8b09f341da6746e746b8f9a3 (patch)
treed5bb089230ae0dfaffacaa0550563ab17efca2bd /cura/PlatformPhysics.py
parent1b9bf6f0b91ed8a1b624492b1793c01e853ae0a5 (diff)
Fix crash when moving the support eraser
CURA-6480
Diffstat (limited to 'cura/PlatformPhysics.py')
-rwxr-xr-xcura/PlatformPhysics.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/cura/PlatformPhysics.py b/cura/PlatformPhysics.py
index 8fffac4501..2710aad91e 100755
--- a/cura/PlatformPhysics.py
+++ b/cura/PlatformPhysics.py
@@ -173,11 +173,15 @@ class PlatformPhysics:
if tool.getPluginId() == "TranslateTool":
for node in Selection.getAllSelectedObjects():
- if node.getBoundingBox().bottom < 0:
+ bounding_box = node.getBoundingBox()
+ if bounding_box is None:
+ continue
+
+ if bounding_box.bottom < 0:
if not node.getDecorator(ZOffsetDecorator.ZOffsetDecorator):
node.addDecorator(ZOffsetDecorator.ZOffsetDecorator())
- node.callDecoration("setZOffset", node.getBoundingBox().bottom)
+ node.callDecoration("setZOffset", bounding_box.bottom)
else:
if node.getDecorator(ZOffsetDecorator.ZOffsetDecorator):
node.removeDecorator(ZOffsetDecorator.ZOffsetDecorator)