mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-22 06:03:57 -06:00
Add default position to fdm extruder definition - CURA-4482
This commit is contained in:
parent
f36c9ffbc0
commit
4701518404
3 changed files with 18 additions and 17 deletions
|
@ -424,23 +424,23 @@ class CuraContainerRegistry(ContainerRegistry):
|
||||||
extruder_stack.addMetaDataEntry("position", "0")
|
extruder_stack.addMetaDataEntry("position", "0")
|
||||||
extruder_stack.setNextStack(machine)
|
extruder_stack.setNextStack(machine)
|
||||||
|
|
||||||
# if machine.userChanges:
|
if machine.userChanges:
|
||||||
# # set existing user changes if found
|
# set existing user changes if found
|
||||||
# extruder_stack.setUserChanges(machine.userChanges)
|
extruder_stack.setUserChanges(machine.userChanges)
|
||||||
# else:
|
else:
|
||||||
# # create empty user changes container otherwise
|
# create empty user changes container otherwise
|
||||||
# user_container = InstanceContainer(extruder_stack.getId() + "_user")
|
user_container = InstanceContainer(extruder_stack.getId() + "_user")
|
||||||
# user_container.addMetaDataEntry("type", "user")
|
user_container.addMetaDataEntry("type", "user")
|
||||||
# user_container.addMetaDataEntry("machine", extruder_stack.getId())
|
user_container.addMetaDataEntry("machine", extruder_stack.getId())
|
||||||
# from cura.CuraApplication import CuraApplication
|
from cura.CuraApplication import CuraApplication
|
||||||
# user_container.addMetaDataEntry("setting_version", CuraApplication.SettingVersion)
|
user_container.addMetaDataEntry("setting_version", CuraApplication.SettingVersion)
|
||||||
# user_container.setDefinition(extruder_definition)
|
user_container.setDefinition(extruder_definition)
|
||||||
# extruder_stack.setUserChanges(user_container)
|
extruder_stack.setUserChanges(user_container)
|
||||||
# self.addContainer(user_container)
|
self.addContainer(user_container)
|
||||||
|
|
||||||
# extruder_stack.setVariantById("default")
|
# extruder_stack.setVariantById("default")
|
||||||
# extruder_stack.setMaterialById("default")
|
extruder_stack.setMaterialById("default")
|
||||||
# extruder_stack.setQualityById("default")
|
extruder_stack.setQualityById("default")
|
||||||
|
|
||||||
self.addContainer(extruder_stack)
|
self.addContainer(extruder_stack)
|
||||||
|
|
||||||
|
|
|
@ -51,7 +51,7 @@ class CuraStackBuilder:
|
||||||
|
|
||||||
if not extruder_definition:
|
if not extruder_definition:
|
||||||
# create extruder stack for single extrusion machines that have no separate extruder definition files
|
# create extruder stack for single extrusion machines that have no separate extruder definition files
|
||||||
extruder_definition = registry.findDefinitionContainers(id = "fdmextruder")
|
extruder_definition = registry.findDefinitionContainers(id = "fdmextruder")[0]
|
||||||
new_extruder_id = registry.uniqueName(machine_definition.getId() + " " + "fdmextruder")
|
new_extruder_id = registry.uniqueName(machine_definition.getId() + " " + "fdmextruder")
|
||||||
new_extruder = cls.createExtruderStack(
|
new_extruder = cls.createExtruderStack(
|
||||||
new_extruder_id,
|
new_extruder_id,
|
||||||
|
|
|
@ -8,7 +8,8 @@
|
||||||
"author": "Ultimaker",
|
"author": "Ultimaker",
|
||||||
"manufacturer": "Unknown",
|
"manufacturer": "Unknown",
|
||||||
"setting_version": 1,
|
"setting_version": 1,
|
||||||
"visible": false
|
"visible": false,
|
||||||
|
"position": "0"
|
||||||
},
|
},
|
||||||
"settings":
|
"settings":
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue