47 lines
976 B
QML
47 lines
976 B
QML
import QtQuick 2.12
|
|
import QtQuick.Layouts 1.12
|
|
|
|
import Controls 1.0 as Controls
|
|
import Screens 1.0 as Screens
|
|
|
|
RowLayout {
|
|
spacing: 20
|
|
|
|
property string title: stack.itemAt(stack.currentIndex).title
|
|
|
|
StackLayout {
|
|
id: stack
|
|
|
|
Screens.TerminalScreen {
|
|
id: terminalScreen
|
|
property string title: qsTr("Terminal")
|
|
}
|
|
|
|
Screens.FirmwareUpdateScreen {
|
|
id: firmwareUpdateScreen
|
|
property string title: qsTr("Firmware update")
|
|
}
|
|
|
|
Layout.fillWidth: true
|
|
Layout.fillHeight: true
|
|
}
|
|
|
|
ColumnLayout {
|
|
spacing: 20
|
|
|
|
Repeater {
|
|
model: [terminalScreen.title, firmwareUpdateScreen.title]
|
|
delegate: Controls.LinkLabel {
|
|
text: modelData
|
|
onClicked: stack.currentIndex = index
|
|
}
|
|
}
|
|
|
|
Item {
|
|
Layout.fillHeight: true
|
|
}
|
|
|
|
Layout.preferredWidth: 180
|
|
}
|
|
}
|