Qt 5.12 ES5 → 7: Use "() =>" and array.includes
This commit is contained in:
@@ -35,18 +35,18 @@ Banner {
|
||||
]
|
||||
|
||||
buttonCallbacks: {
|
||||
"accept": function(button) {
|
||||
"accept": button => {
|
||||
button.loading = true
|
||||
py.callClientCoro(
|
||||
chatPage.userId, "join", [chatPage.roomId], function() {
|
||||
chatPage.userId, "join", [chatPage.roomId], () => {
|
||||
button.loading = false
|
||||
})
|
||||
},
|
||||
|
||||
"decline": function(button) {
|
||||
"decline": button => {
|
||||
button.loading = true
|
||||
py.callClientCoro(
|
||||
chatPage.userId, "room_leave", [chatPage.roomId], function() {
|
||||
chatPage.userId, "room_leave", [chatPage.roomId], () => {
|
||||
button.loading = false
|
||||
})
|
||||
}
|
||||
|
@@ -23,10 +23,10 @@ Banner {
|
||||
]
|
||||
|
||||
buttonCallbacks: {
|
||||
"forget": function(button) {
|
||||
"forget": button => {
|
||||
button.loading = true
|
||||
py.callClientCoro(
|
||||
chatPage.userId, "room_forget", [chatPage.roomId], function() {
|
||||
chatPage.userId, "room_forget", [chatPage.roomId], () => {
|
||||
button.loading = false
|
||||
})
|
||||
}
|
||||
|
@@ -21,8 +21,8 @@ Banner {
|
||||
]
|
||||
|
||||
buttonCallbacks: {
|
||||
"inspect": function(button) {
|
||||
"inspect": button => {
|
||||
print("show")
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user