[Logout Dialog] Add "Hibernate" option

We offer both Suspend and Hibernate in the application launcher so we should do the same here

BUG: 398184
FIXED-IN: 5.14.0

Differential Revision: https://phabricator.kde.org/D15287
wilder-5.14
Kai Uwe Broulik 8 years ago
parent 0a56e67cd5
commit 33746fa4e7
  1. 17
      lookandfeel/contents/logout/Logout.qml

@ -49,6 +49,10 @@ PlasmaCore.ColorScope {
function sleepRequested() {
root.suspendRequested(2);
}
function hibernateRequested() {
root.suspendRequested(4);
}
property real timeout: 30
property real remainingTime: root.timeout
@ -159,15 +163,24 @@ PlasmaCore.ColorScope {
text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Suspend")
action: root.sleepRequested
KeyNavigation.left: logoutButton
KeyNavigation.right: rebootButton
KeyNavigation.right: hibernateButton
visible: spdMethods.SuspendState
}
LogoutButton {
id: hibernateButton
iconSource: "system-suspend-hibernate"
text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Hibernate")
action: root.hibernateRequested
KeyNavigation.left: suspendButton
KeyNavigation.right: rebootButton
visible: spdMethods.HibernateState
}
LogoutButton {
id: rebootButton
iconSource: "system-reboot"
text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Reboot")
action: root.rebootRequested
KeyNavigation.left: suspendButton
KeyNavigation.left: hibernateButton
KeyNavigation.right: shutdownButton
focus: sdtype == ShutdownType.ShutdownTypeReboot
visible: maysd

Loading…
Cancel
Save