Make it possible to go back from any page by having a back button on the toolbar
This commit is contained in:
parent
46b57003cd
commit
d741465473
1 changed files with 11 additions and 4 deletions
|
@ -30,6 +30,17 @@ ApplicationWindow
|
||||||
width: 400
|
width: 400
|
||||||
height: 500
|
height: 500
|
||||||
|
|
||||||
|
toolBar: RowLayout {
|
||||||
|
Button {
|
||||||
|
text: "<"
|
||||||
|
onClicked: stack.pop()
|
||||||
|
}
|
||||||
|
Label {
|
||||||
|
Layout.fillWidth: true
|
||||||
|
text: "KDE Connect"
|
||||||
|
font.pointSize: 20
|
||||||
|
}
|
||||||
|
}
|
||||||
StackView {
|
StackView {
|
||||||
id: stack
|
id: stack
|
||||||
anchors {
|
anchors {
|
||||||
|
@ -85,10 +96,6 @@ ApplicationWindow
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: deviceView
|
id: deviceView
|
||||||
property QtObject currentDevice
|
property QtObject currentDevice
|
||||||
Button {
|
|
||||||
text: "<"
|
|
||||||
onClicked: stack.pop()
|
|
||||||
}
|
|
||||||
Loader {
|
Loader {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
Loading…
Reference in a new issue