Set machine isAbractMachine in workspace dialog initialisation

This commit is contained in:
c.lamboo 2022-11-15 15:35:16 +01:00
parent a30fbf5a8f
commit dc65e801d0

View file

@ -9,6 +9,7 @@ from typing import cast, Dict, List, Optional, Tuple, Any, Set
import xml.etree.ElementTree as ET import xml.etree.ElementTree as ET
from UM.Util import parseBool
from UM.Workspace.WorkspaceReader import WorkspaceReader from UM.Workspace.WorkspaceReader import WorkspaceReader
from UM.Application import Application from UM.Application import Application
@ -601,6 +602,7 @@ class ThreeMFWorkspaceReader(WorkspaceReader):
self._dialog.setUpdatableMachines(updatable_machines) self._dialog.setUpdatableMachines(updatable_machines)
self._dialog.setMachineName(machine_name) self._dialog.setMachineName(machine_name)
self._dialog.setIsNetworkedMachine(existing_global_stack.hasNetworkedConnection()) self._dialog.setIsNetworkedMachine(existing_global_stack.hasNetworkedConnection())
self._dialog.setIsAbstractMachine(parseBool(existing_global_stack.getMetaDataEntry("is_abstract_machine", False)))
self._dialog.setMachineToOverride(global_stack_id) self._dialog.setMachineToOverride(global_stack_id)
self._dialog.setMaterialLabels(material_labels) self._dialog.setMaterialLabels(material_labels)
self._dialog.setMachineType(machine_type) self._dialog.setMachineType(machine_type)