mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-05-08 14:39:01 +08:00
69 lines
1.6 KiB
QML
69 lines
1.6 KiB
QML
// Copyright (c) 2015 Ultimaker B.V.
|
|
// Cura is released under the terms of the AGPLv3 or higher.
|
|
|
|
import QtQuick 2.2
|
|
import QtQuick.Controls 1.1
|
|
import QtQuick.Layouts 1.1
|
|
import QtQuick.Window 2.1
|
|
|
|
import UM 1.0 as UM
|
|
|
|
ColumnLayout {
|
|
id: wizardPage
|
|
property string title
|
|
property int pageWidth
|
|
property int pageHeight
|
|
|
|
SystemPalette{id: palette}
|
|
//signal openFile(string fileName)
|
|
//signal closeWizard()
|
|
|
|
width: wizardPage.pageWidth
|
|
height: wizardPage.pageHeight
|
|
|
|
Connections {
|
|
target: elementRoot
|
|
onResize: {
|
|
wizardPage.width = pageWidth
|
|
wizardPage.height = pageHeight
|
|
}
|
|
}
|
|
|
|
Label {
|
|
text: parent.title
|
|
font.pointSize: 18;
|
|
}
|
|
|
|
Label {
|
|
//: Add Printer wizard page description
|
|
text: qsTr("Please select the type of printer:");
|
|
}
|
|
|
|
ScrollView {
|
|
Layout.fillWidth: true;
|
|
|
|
ListView {
|
|
id: machineList;
|
|
model: UM.Models.availableMachinesModel
|
|
delegate: RadioButton {
|
|
exclusiveGroup: printerGroup;
|
|
text: model.name;
|
|
onClicked: {
|
|
ListView.view.currentIndex = index;
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
Label {
|
|
//: Add Printer wizard field label
|
|
text: qsTr("Printer Name:");
|
|
}
|
|
|
|
TextField { id: machineName; Layout.fillWidth: true; text: machineList.model.getItem(machineList.currentIndex).name }
|
|
|
|
Item { Layout.fillWidth: true; Layout.fillHeight: true; }
|
|
|
|
ExclusiveGroup { id: printerGroup; }
|
|
} |