diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 00e1b69a15..6c5bc61cbe 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -3,17 +3,14 @@ image: registry.gitlab.com/ultimaker/cura/cura-build-environment:centos7 stages: - build -build-and-test: +build and test linux: stage: build + tags: + - cura + - docker + - linux script: - docker/build.sh artifacts: paths: - build - -build-and-test_merge-requests: - stage: build - script: - - docker/build.sh - only: - - merge_requests diff --git a/cura/PreviewPass.py b/cura/PreviewPass.py index 2fe6e7971f..8465af4b83 100644 --- a/cura/PreviewPass.py +++ b/cura/PreviewPass.py @@ -1,9 +1,8 @@ # Copyright (c) 2018 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from typing import Optional, TYPE_CHECKING +from typing import Optional, TYPE_CHECKING, cast -from numpy import cast from UM.Application import Application from UM.Resources import Resources diff --git a/resources/qml/Preferences/Materials/MaterialsPage.qml b/resources/qml/Preferences/Materials/MaterialsPage.qml index f4d4f00c55..0760bbfb57 100644 --- a/resources/qml/Preferences/Materials/MaterialsPage.qml +++ b/resources/qml/Preferences/Materials/MaterialsPage.qml @@ -45,6 +45,11 @@ Item materialListView.expandActiveMaterial(active_root_material_id) } + function setExpandedActiveMaterial(root_material_id) + { + materialListView.expandActiveMaterial(root_material_id) + } + // When loaded, try to select the active material in the tree Component.onCompleted: resetExpandedActiveMaterial() diff --git a/resources/qml/Preferences/Materials/MaterialsSlot.qml b/resources/qml/Preferences/Materials/MaterialsSlot.qml index 86f705f634..0e60bb6558 100644 --- a/resources/qml/Preferences/Materials/MaterialsSlot.qml +++ b/resources/qml/Preferences/Materials/MaterialsSlot.qml @@ -60,7 +60,7 @@ Rectangle { materialList.currentBrand = material.brand materialList.currentType = material.brand + "_" + material.material - base.currentItem = material + base.setExpandedActiveMaterial(material.root_material_id) } hoverEnabled: true onEntered: { materialSlot.hovered = true }