mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
Greatly simplify the SimulationViewProxy
This commit is contained in:
parent
ced14c7daf
commit
9c2f8a94d5
2 changed files with 60 additions and 124 deletions
|
@ -84,7 +84,7 @@ class SimulationView(CuraView):
|
|||
self._old_composite_shader = None # type: Optional["ShaderProgram"]
|
||||
|
||||
self._global_container_stack = None # type: Optional[ContainerStack]
|
||||
self._proxy = SimulationViewProxy()
|
||||
self._proxy = None
|
||||
self._controller.getScene().getRoot().childrenChanged.connect(self._onSceneChanged)
|
||||
|
||||
self._resetSettings()
|
||||
|
@ -441,6 +441,8 @@ class SimulationView(CuraView):
|
|||
## Hackish way to ensure the proxy is already created, which ensures that the layerview.qml is already created
|
||||
# as this caused some issues.
|
||||
def getProxy(self, engine, script_engine):
|
||||
if self._proxy is None:
|
||||
self._proxy = SimulationViewProxy(self)
|
||||
return self._proxy
|
||||
|
||||
def endRendering(self) -> None:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue