Increase agressiveness of short circuit logic; Just check if the node is slicable

That should also filter out platform, buildVolume and convexHulLNodes
This commit is contained in:
Jaime van Kessel 2019-02-19 18:00:20 +01:00
parent b61bf3df4d
commit 3f18b0b974
3 changed files with 5 additions and 5 deletions

View File

@ -129,8 +129,8 @@ class BuildVolume(SceneNode):
def _onSceneChanged(self, source):
if self._global_container_stack:
# Just ignore the camera scene updates. The build volume won't change because of it!
if not isinstance(source, Camera):
# Ignore anything that is not something we can slice in the first place!
if source.callDecoration("isSliceable"):
self._scene_change_timer.start()
def _onSceneChangeTimerFinished(self):

View File

@ -17,7 +17,6 @@ from cura.Scene import ZOffsetDecorator
import random # used for list shuffling
class PlatformPhysics:
def __init__(self, controller, volume):
super().__init__()
@ -40,8 +39,9 @@ class PlatformPhysics:
Application.getInstance().getPreferences().addPreference("physics/automatic_drop_down", True)
def _onSceneChanged(self, source):
if not source.getMeshData():
if not source.callDecoration("isSliceable"):
return
self._change_timer.start()
def _onChangeTimerFinished(self):

View File

@ -477,7 +477,7 @@ class CuraEngineBackend(QObject, Backend):
#
# \param source The scene node that was changed.
def _onSceneChanged(self, source: SceneNode) -> None:
if not isinstance(source, SceneNode) or isinstance(source, Camera):
if not source.callDecoration("isSliceable"):
return
# This case checks if the source node is a node that contains GCode. In this case the