Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'resources/qml/ExpandableComponent.qml')
-rw-r--r--resources/qml/ExpandableComponent.qml22
1 files changed, 5 insertions, 17 deletions
diff --git a/resources/qml/ExpandableComponent.qml b/resources/qml/ExpandableComponent.qml
index e5eab3bd93..9cc84e18dc 100644
--- a/resources/qml/ExpandableComponent.qml
+++ b/resources/qml/ExpandableComponent.qml
@@ -155,7 +155,7 @@ Item
}
}
- UM.RecolorImage
+ UM.ColorImage
{
id: collapseButton
anchors
@@ -249,13 +249,13 @@ Item
}
property var clickPos: Qt.point(0, 0)
property bool dragging: false
- onPressed:
+ onPressed: (mouse) =>
{
clickPos = Qt.point(mouse.x, mouse.y);
dragging = true
}
- onPositionChanged:
+ onPositionChanged: (mouse) =>
{
if(dragging)
{
@@ -266,10 +266,8 @@ Item
}
}
}
- onReleased:
- {
- dragging = false
- }
+ onReleased: dragging = false
+
onDoubleClicked:
{
@@ -305,14 +303,6 @@ Item
padding: UM.Theme.getSize("default_margin").width
contentItem: Item {}
-
- onContentItemChanged:
- {
- // Since we want the size of the content to be set by the size of the content,
- // we need to do it like this.
- content.width = contentItem.width + 2 * content.padding
- content.height = contentItem.height + 2 * content.padding
- }
}
}
@@ -322,10 +312,8 @@ Item
{
// Since it could be that the content is dynamically populated, we should also take these changes into account.
target: content.contentItem
- function onWidthChanged() { content.width = content.contentItem.width + 2 * content.padding }
function onHeightChanged()
{
- content.height = content.contentItem.height + 2 * content.padding
contentContainer.height = contentHeader.height + content.height
}
}