mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-08-06 05:23:58 -06:00
CURA-4870 Modify the dropdown look and feel
This commit is contained in:
parent
6952e3f5c1
commit
135208bfee
7 changed files with 176 additions and 148 deletions
72
resources/qml/Menus/ConfigurationMenu/ConfigurationItem.qml
Normal file
72
resources/qml/Menus/ConfigurationMenu/ConfigurationItem.qml
Normal file
|
@ -0,0 +1,72 @@
|
|||
// Copyright (c) 2018 Ultimaker B.V.
|
||||
// Cura is released under the terms of the LGPLv3 or higher.
|
||||
|
||||
import QtQuick 2.7
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import UM 1.2 as UM
|
||||
import Cura 1.0 as Cura
|
||||
|
||||
Rectangle
|
||||
{
|
||||
id: configurationItem
|
||||
|
||||
property var printer: null
|
||||
signal configurationSelected()
|
||||
|
||||
height: childrenRect.height
|
||||
border.width: UM.Theme.getSize("default_lining").width
|
||||
border.color: "black"
|
||||
|
||||
Column
|
||||
{
|
||||
id: contentColumn
|
||||
padding: UM.Theme.getSize("default_margin").width
|
||||
spacing: UM.Theme.getSize("default_margin").height
|
||||
|
||||
Label
|
||||
{
|
||||
text: printer.name
|
||||
}
|
||||
|
||||
Row
|
||||
{
|
||||
id: extruderRow
|
||||
|
||||
width: parent.width
|
||||
height: childrenRect.height
|
||||
|
||||
spacing: UM.Theme.getSize("default_margin").width
|
||||
|
||||
Repeater
|
||||
{
|
||||
height: childrenRect.height
|
||||
model: printer.extruders
|
||||
delegate: PrintCoreConfiguration
|
||||
{
|
||||
printCoreConfiguration: modelData
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Rectangle
|
||||
// {
|
||||
// id: buildplateInformation
|
||||
//
|
||||
// Label
|
||||
// {
|
||||
// text: printer.name + "-" + printer.type
|
||||
// }
|
||||
// }
|
||||
}
|
||||
|
||||
MouseArea
|
||||
{
|
||||
id: mouse
|
||||
anchors.fill: parent
|
||||
onClicked: configurationSelected()
|
||||
hoverEnabled: true
|
||||
onEntered: parent.border.color = UM.Theme.getColor("primary_hover")
|
||||
onExited: parent.border.color = "black"
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue