chore: simplify password unlocking via keyboard
Turns out it is not needed to check whether an action is enabled before triggerin it: the trigger is automatically suppressed if the action is not yet enabled.master
parent
d00111edc9
commit
8ddfdaba42
|
@ -59,11 +59,7 @@ Kirigami.ScrollablePage {
|
|||
text: ""
|
||||
Kirigami.FormData.label: i18nc("@label:textbox", "Password:")
|
||||
enabled: !vm.busy
|
||||
onAccepted: {
|
||||
if (unlockAction.enabled) {
|
||||
unlockAction.trigger()
|
||||
}
|
||||
}
|
||||
onAccepted: unlockAction.trigger()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue