some more thoughts about state management
This commit is contained in:
parent
437e76067f
commit
b38ed2107b
13 changed files with 125 additions and 13 deletions
qml/Forms
|
@ -6,11 +6,13 @@ import magpie.Components as Components
|
|||
|
||||
Column {
|
||||
signal register()
|
||||
signal loggingIn(value: bool)
|
||||
|
||||
function login(login, password) {
|
||||
if (modal.inProgress)
|
||||
return;
|
||||
|
||||
loggingIn(true);
|
||||
loginField.text = login;
|
||||
passwordField.text = password;
|
||||
|
||||
|
@ -28,6 +30,7 @@ Column {
|
|||
else
|
||||
modal.status = qsTr("Success");
|
||||
|
||||
loggingIn(false);
|
||||
if (!!result)
|
||||
modal.close();
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue