lock: refactor
This commit is contained in:
parent
c98a0fb267
commit
53bfe29a40
2 changed files with 2 additions and 5 deletions
|
|
@ -124,7 +124,7 @@ ColumnLayout {
|
|||
}
|
||||
|
||||
Keys.onPressed: event => {
|
||||
if (!root.lock.locked)
|
||||
if (root.lock.unlocking)
|
||||
return;
|
||||
|
||||
if (event.key === Qt.Key_Enter || event.key === Qt.Key_Return)
|
||||
|
|
|
|||
|
|
@ -13,10 +13,8 @@ WlSessionLockSurface {
|
|||
required property WlSessionLock lock
|
||||
required property Pam pam
|
||||
|
||||
readonly property alias unlocking: unlockAnim.running
|
||||
readonly property bool animating: initAnim.running || unlockAnim.running
|
||||
property bool locked
|
||||
|
||||
Component.onCompleted: locked = true
|
||||
|
||||
color: "transparent"
|
||||
|
||||
|
|
@ -24,7 +22,6 @@ WlSessionLockSurface {
|
|||
target: root.lock
|
||||
|
||||
function onUnlock(): void {
|
||||
root.locked = false;
|
||||
unlockAnim.start();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue