Move the logout button to the page’s toolbar
This commit is contained in:
parent
7343174056
commit
5cc7192387
|
@ -1,23 +1,22 @@
|
||||||
pragma ComponentBehavior: Bound
|
pragma ComponentBehavior: Bound
|
||||||
import QtQuick
|
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
|
import QtQuick.Layouts
|
||||||
|
|
||||||
Page {
|
Page {
|
||||||
title: qsTr("Reservations")
|
title: qsTr("Reservations")
|
||||||
|
|
||||||
Button {
|
header: ToolBar {
|
||||||
action: logoutAction
|
RowLayout {
|
||||||
}
|
anchors.fill: parent
|
||||||
|
|
||||||
Action {
|
ToolButton {
|
||||||
id: logoutAction
|
icon.name: "system-log-out"
|
||||||
|
text: qsTr("&Log out")
|
||||||
|
|
||||||
icon.name: "system-log-out"
|
onClicked: function () {
|
||||||
shortcut: "Ctrl+L"
|
Database.close();
|
||||||
text: qsTr("&Log out")
|
}
|
||||||
|
}
|
||||||
onTriggered: function () {
|
|
||||||
Database.close();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue