mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-09 07:56:22 -06:00
Improve styling of Firmware update window
Contributes to Ultimaker/Uranium#8
This commit is contained in:
parent
59fbf72ac3
commit
7878456c9b
1 changed files with 38 additions and 14 deletions
|
@ -3,15 +3,30 @@
|
||||||
|
|
||||||
import QtQuick 2.1
|
import QtQuick 2.1
|
||||||
import QtQuick.Controls 1.1
|
import QtQuick.Controls 1.1
|
||||||
import QtQuick.Layouts 1.1
|
import QtQuick.Window 2.1
|
||||||
Rectangle
|
|
||||||
{
|
|
||||||
width: 300; height: 100
|
|
||||||
ColumnLayout
|
|
||||||
{
|
|
||||||
|
|
||||||
Text
|
Rectangle
|
||||||
|
{
|
||||||
|
id: base;
|
||||||
|
|
||||||
|
width: 500 * Screen.devicePixelRatio;
|
||||||
|
height: 100 * Screen.devicePixelRatio;
|
||||||
|
|
||||||
|
color: palette.window;
|
||||||
|
|
||||||
|
signal close();
|
||||||
|
|
||||||
|
Column
|
||||||
|
{
|
||||||
|
anchors.fill: parent;
|
||||||
|
anchors.margins: 8 * Screen.devicePixelRatio;
|
||||||
|
Label
|
||||||
{
|
{
|
||||||
|
anchors {
|
||||||
|
left: parent.left;
|
||||||
|
right: parent.right;
|
||||||
|
}
|
||||||
|
|
||||||
text: {
|
text: {
|
||||||
if (manager.progress == 0)
|
if (manager.progress == 0)
|
||||||
{
|
{
|
||||||
|
@ -29,6 +44,8 @@ Rectangle
|
||||||
return qsTr("Updating firmware.")
|
return qsTr("Updating firmware.")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
wrapMode: Text.Wrap;
|
||||||
}
|
}
|
||||||
ProgressBar
|
ProgressBar
|
||||||
{
|
{
|
||||||
|
@ -36,13 +53,20 @@ Rectangle
|
||||||
value: manager.progress
|
value: manager.progress
|
||||||
minimumValue: 0;
|
minimumValue: 0;
|
||||||
maximumValue: 100;
|
maximumValue: 100;
|
||||||
Layout.maximumWidth:parent.width
|
anchors {
|
||||||
Layout.preferredWidth:230
|
left: parent.left;
|
||||||
Layout.preferredHeight:25
|
right: parent.right;
|
||||||
Layout.minimumWidth:230
|
}
|
||||||
Layout.minimumHeight:25
|
|
||||||
width: 230
|
}
|
||||||
height: 25
|
Button {
|
||||||
|
anchors.right: parent.right;
|
||||||
|
text: qsTr("Close");
|
||||||
|
onClicked: base.close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
SystemPalette {
|
||||||
|
id: palette;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue