Updated other wizard pages to fit the changed wizard.qml

This commit is contained in:
Jaime van Kessel 2015-08-17 15:24:24 +02:00
parent d69ca6fa41
commit a7f33ea5e7
2 changed files with 64 additions and 31 deletions

View file

@ -8,48 +8,64 @@ import QtQuick.Window 2.1
import UM 1.0 as UM import UM 1.0 as UM
ColumnLayout { Column
{
id: wizardPage id: wizardPage
property string title property string title
property int pageWidth
property int pageHeight
anchors.fill: parent; anchors.fill: parent;
Label { Label
{
text: parent.title text: parent.title
font.pointSize: 18; font.pointSize: 18;
} }
Label { Label
{
//: Add Printer wizard page description //: Add Printer wizard page description
text: qsTr("Please select the type of printer:"); text: qsTr("Please select the type of printer:");
} }
ScrollView { ScrollView
Layout.fillWidth: true; {
height: parent.height - 50
ListView { width: parent.width
ListView
{
id: machineList; id: machineList;
model: UM.Models.availableMachinesModel model: UM.Models.availableMachinesModel
delegate: RadioButton { delegate: RadioButton
{
exclusiveGroup: printerGroup; exclusiveGroup: printerGroup;
text: model.name; text: model.name;
onClicked: { onClicked:
{
ListView.view.currentIndex = index; ListView.view.currentIndex = index;
} }
} }
} }
} }
Label { Label
{
//: Add Printer wizard field label //: Add Printer wizard field label
text: qsTr("Printer Name:"); text: qsTr("Printer Name:");
} }
TextField { id: machineName; Layout.fillWidth: true; text: machineList.model.getItem(machineList.currentIndex).name } TextField
{
id: machineName; Layout.fillWidth: true; text: machineList.model.getItem(machineList.currentIndex).name
Item { Layout.fillWidth: true; Layout.fillHeight: true; } }
ExclusiveGroup { id: printerGroup; } Item
{
Layout.fillWidth: true;
Layout.fillHeight: true;
}
ExclusiveGroup
{
id: printerGroup;
}
} }

View file

@ -8,47 +8,64 @@ import QtQuick.Window 2.1
import UM 1.0 as UM import UM 1.0 as UM
ColumnLayout { Column
{
id: wizardPage id: wizardPage
property string title property string title
property int pageWidth
property int pageHeight
anchors.fill: parent; anchors.fill: parent;
Label { Label
{
text: parent.title text: parent.title
font.pointSize: 18; font.pointSize: 18;
} }
Label { Label
{
//: Add Printer wizard page description //: Add Printer wizard page description
text: qsTr("Please select the type of printer:"); text: qsTr("Please select the type of printer:");
} }
ScrollView { ScrollView
Layout.fillWidth: true; {
height: parent.height - 50
ListView { width: parent.width
ListView
{
id: machineList; id: machineList;
model: UM.Models.availableMachinesModel model: UM.Models.availableMachinesModel
delegate: RadioButton { delegate: RadioButton
{
exclusiveGroup: printerGroup; exclusiveGroup: printerGroup;
text: model.name; text: model.name;
onClicked: { onClicked:
{
ListView.view.currentIndex = index; ListView.view.currentIndex = index;
} }
} }
} }
} }
Label { Label
{
//: Add Printer wizard field label //: Add Printer wizard field label
text: qsTr("Printer Name:"); text: qsTr("Printer Name:");
} }
TextField { id: machineName; Layout.fillWidth: true; text: machineList.model.getItem(machineList.currentIndex).name } TextField
{
id: machineName; Layout.fillWidth: true; text: machineList.model.getItem(machineList.currentIndex).name
Item { Layout.fillWidth: true; Layout.fillHeight: true; } }
ExclusiveGroup { id: printerGroup; } Item
{
Layout.fillWidth: true;
Layout.fillHeight: true;
}
ExclusiveGroup
{
id: printerGroup;
}
} }