mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-11 20:58:58 +08:00
Get intents for every active extruder, not every used extruder
We want the intents for basically any extruder, not just the one that would get used by a slice using the current settings for extruder_nr. Contributes to issue CURA-6597.
This commit is contained in:
parent
951b91e3d8
commit
3cce33be6f
@ -73,13 +73,13 @@ class IntentManager(QObject):
|
||||
return [("default", "normal")]
|
||||
# TODO: We now do this (return a default) if the global stack is missing, but not in the code below,
|
||||
# even though there should always be defaults. The problem then is what to do with the quality_types.
|
||||
# Currently _also_ inconsistent with 'currentAvailableIntentCategoreis', which _does_ return default.
|
||||
# Currently _also_ inconsistent with 'currentAvailableIntentCategories', which _does_ return default.
|
||||
quality_groups = application.getQualityManager().getQualityGroups(global_stack)
|
||||
available_quality_types = {quality_group.quality_type for quality_group in quality_groups.values() if quality_group.node_for_global is not None}
|
||||
|
||||
final_intent_ids = set() # type: Set[str]
|
||||
current_definition_id = global_stack.definition.getMetaDataEntry("id")
|
||||
for extruder_stack in ExtruderManager.getInstance().getUsedExtruderStacks():
|
||||
for extruder_stack in ExtruderManager.getInstance().getActiveExtruderStacks():
|
||||
nozzle_name = extruder_stack.variant.getMetaDataEntry("name")
|
||||
material_id = extruder_stack.material.getMetaDataEntry("base_file")
|
||||
final_intent_ids |= {metadata["id"] for metadata in self.intentMetadatas(current_definition_id, nozzle_name, material_id) if metadata["quality_type"] in available_quality_types}
|
||||
|
Loading…
x
Reference in New Issue
Block a user