Changeset View
Changeset View
Standalone View
Standalone View
lookandfeel/contents/logout/Logout.qml
Show First 20 Lines • Show All 135 Lines • ▼ Show 20 Line(s) | 133 | anchors { | |||
---|---|---|---|---|---|
136 | horizontalCenter: parent.horizontalCenter | 136 | horizontalCenter: parent.horizontalCenter | ||
137 | } | 137 | } | ||
138 | spacing: units.largeSpacing | 138 | spacing: units.largeSpacing | ||
139 | 139 | | |||
140 | height: Math.max(implicitHeight, units.gridUnit * 10) | 140 | height: Math.max(implicitHeight, units.gridUnit * 10) | ||
141 | width: Math.max(implicitWidth, units.gridUnit * 16) | 141 | width: Math.max(implicitWidth, units.gridUnit * 16) | ||
142 | 142 | | |||
143 | PlasmaComponents.Label { | 143 | PlasmaComponents.Label { | ||
144 | font.pointSize: 11 | 144 | font.pointSize: theme.defaultFont.pointSize + 1 | ||
145 | Layout.maximumWidth: units.gridUnit * 16 | 145 | Layout.maximumWidth: units.gridUnit * 16 | ||
146 | Layout.alignment: Qt.AlignHCenter | 146 | Layout.alignment: Qt.AlignHCenter | ||
147 | Layout.fillWidth: true | 147 | Layout.fillWidth: true | ||
148 | horizontalAlignment: Text.AlignHCenter | 148 | horizontalAlignment: Text.AlignHCenter | ||
149 | wrapMode: Text.WordWrap | 149 | wrapMode: Text.WordWrap | ||
150 | font.italic: true | 150 | font.italic: true | ||
151 | text: i18ndp("plasma_lookandfeel_org.kde.lookandfeel", | 151 | text: i18ndp("plasma_lookandfeel_org.kde.lookandfeel", | ||
152 | "One other user is currently logged in. If the computer is shut down or restarted, that user may lose work.", | 152 | "One other user is currently logged in. If the computer is shut down or restarted, that user may lose work.", | ||
▲ Show 20 Lines • Show All 51 Lines • ▼ Show 20 Line(s) | 199 | LogoutButton { | |||
204 | KeyNavigation.left: shutdownButton | 204 | KeyNavigation.left: shutdownButton | ||
205 | KeyNavigation.right: suspendButton | 205 | KeyNavigation.right: suspendButton | ||
206 | focus: sdtype == ShutdownType.ShutdownTypeNone | 206 | focus: sdtype == ShutdownType.ShutdownTypeNone | ||
207 | visible: canLogout | 207 | visible: canLogout | ||
208 | } | 208 | } | ||
209 | } | 209 | } | ||
210 | 210 | | |||
211 | PlasmaComponents.Label { | 211 | PlasmaComponents.Label { | ||
212 | font.pointSize: 11 | 212 | font.pointSize: theme.defaultFont.pointSize + 1 | ||
213 | Layout.alignment: Qt.AlignHCenter | 213 | Layout.alignment: Qt.AlignHCenter | ||
214 | //opacity, as visible would re-layout | 214 | //opacity, as visible would re-layout | ||
215 | opacity: countDownTimer.running ? 1 : 0 | 215 | opacity: countDownTimer.running ? 1 : 0 | ||
216 | Behavior on opacity { | 216 | Behavior on opacity { | ||
217 | OpacityAnimator { | 217 | OpacityAnimator { | ||
218 | duration: units.longDuration | 218 | duration: units.longDuration | ||
219 | easing.type: Easing.InOutQuad | 219 | easing.type: Easing.InOutQuad | ||
220 | } | 220 | } | ||
221 | } | 221 | } | ||
222 | text: { | 222 | text: { | ||
223 | switch (sdtype) { | 223 | switch (sdtype) { | ||
224 | case ShutdownType.ShutdownTypeReboot: | 224 | case ShutdownType.ShutdownTypeReboot: | ||
225 | return i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Restarting in 1 second", "Restarting in %1 seconds", root.remainingTime); | 225 | return i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Restarting in 1 second", "Restarting in %1 seconds", root.remainingTime); | ||
226 | case ShutdownType.ShutdownTypeHalt: | 226 | case ShutdownType.ShutdownTypeHalt: | ||
227 | return i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Shutting down in 1 second", "Shutting down in %1 seconds", root.remainingTime); | 227 | return i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Shutting down in 1 second", "Shutting down in %1 seconds", root.remainingTime); | ||
228 | default: | 228 | default: | ||
229 | return i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Logging out in 1 second", "Logging out in %1 seconds", root.remainingTime); | 229 | return i18ndp("plasma_lookandfeel_org.kde.lookandfeel", "Logging out in 1 second", "Logging out in %1 seconds", root.remainingTime); | ||
230 | } | 230 | } | ||
231 | } | 231 | } | ||
232 | } | 232 | } | ||
233 | 233 | | |||
234 | RowLayout { | 234 | RowLayout { | ||
235 | Layout.alignment: Qt.AlignHCenter | 235 | Layout.alignment: Qt.AlignHCenter | ||
236 | PlasmaComponents.Button { | 236 | PlasmaComponents.Button { | ||
237 | font.pointSize: 11 | 237 | font.pointSize: theme.defaultFont.pointSize + 1 | ||
238 | enabled: root.currentAction != null | 238 | enabled: root.currentAction != null | ||
239 | text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "OK") | 239 | text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "OK") | ||
240 | onClicked: root.currentAction() | 240 | onClicked: root.currentAction() | ||
241 | } | 241 | } | ||
242 | PlasmaComponents.Button { | 242 | PlasmaComponents.Button { | ||
243 | font.pointSize: 11 | 243 | font.pointSize: theme.defaultFont.pointSize + 1 | ||
244 | text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Cancel") | 244 | text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Cancel") | ||
245 | onClicked: root.cancelRequested() | 245 | onClicked: root.cancelRequested() | ||
246 | } | 246 | } | ||
247 | } | 247 | } | ||
248 | } | 248 | } | ||
249 | } | 249 | } |