Qt 5.12 ES5 → 7: Use "() =>" and array.includes
This commit is contained in:
@@ -22,11 +22,11 @@ Item {
|
||||
]
|
||||
|
||||
buttonCallbacks: {
|
||||
"yes": function(button) {
|
||||
"yes": button => {
|
||||
py.callCoro("save_account", [userId])
|
||||
pageStack.showPage("Default")
|
||||
},
|
||||
"no": function(button) {
|
||||
"no": button => {
|
||||
py.callCoro("forget_account", [userId])
|
||||
pageStack.showPage("Default")
|
||||
},
|
||||
|
@@ -23,13 +23,13 @@ Item {
|
||||
]
|
||||
|
||||
buttonCallbacks: {
|
||||
"register": function(button) {},
|
||||
"register": button => {},
|
||||
|
||||
"login": function(button) {
|
||||
"login": button => {
|
||||
button.loading = true
|
||||
var args = [idField.text, passwordField.text]
|
||||
|
||||
py.callCoro("login_client", args, function(user_id) {
|
||||
py.callCoro("login_client", args, user_id => {
|
||||
pageStack.showPage(
|
||||
"RememberAccount",
|
||||
{"loginWith": loginWith, "userId": user_id}
|
||||
@@ -38,7 +38,7 @@ Item {
|
||||
})
|
||||
},
|
||||
|
||||
"forgot": function(button) {}
|
||||
"forgot": button => {}
|
||||
}
|
||||
|
||||
HRowLayout {
|
||||
|
Reference in New Issue
Block a user