Merge branch 'master' of ssh://github.com/Ultimaker/Cura

This commit is contained in:
Ghostkeeper 2019-09-03 16:42:45 +02:00
commit e2ed6f03e2
No known key found for this signature in database
GPG key ID: 86BEF881AE2CF276
4 changed files with 53 additions and 4 deletions

View file

@ -93,7 +93,11 @@ class CuraProfileReader(ProfileReader):
Logger.log("e", "Error while trying to parse profile: %s", str(e))
return None
active_quality_definition = getMachineDefinitionIDForQualitySearch(CuraApplication.getInstance().getGlobalContainerStack().definition)
global_stack = CuraApplication.getInstance().getGlobalContainerStack()
if global_stack is None:
return None
active_quality_definition = getMachineDefinitionIDForQualitySearch(global_stack.definition)
if profile.getMetaDataEntry("definition") != active_quality_definition:
profile.setMetaDataEntry("definition", active_quality_definition)
return profile

View file

@ -139,6 +139,10 @@ class SolidView(View):
shade_factor * int(material_color[5:7], 16) / 255,
1.0
]
# Color the currently selected face-id.
face = Selection.getSelectedFace()
uniforms["selected_face"] = (Selection.getMaxFaceSelectionId() + 1) if not face or node != face[0] else face[1]
except ValueError:
pass