2023-04-09 13:35:35 +08:00
|
|
|
// SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
|
2023-06-09 01:16:23 +08:00
|
|
|
callbacks["UpdateAvatar"] = (jsonData) => {
|
2022-04-30 15:27:56 +08:00
|
|
|
mainWindow.busy = false;
|
|
|
|
Self.avatar = jsonData;
|
2024-06-10 14:58:48 +08:00
|
|
|
toast.show(luatr("Update avatar done."));
|
2022-03-27 20:00:29 +08:00
|
|
|
}
|
|
|
|
|
2023-06-09 01:16:23 +08:00
|
|
|
callbacks["UpdatePassword"] = (jsonData) => {
|
2022-04-30 15:27:56 +08:00
|
|
|
mainWindow.busy = false;
|
|
|
|
if (jsonData === "1")
|
2024-06-10 14:58:48 +08:00
|
|
|
toast.show(luatr("Update password done."));
|
2022-04-30 15:27:56 +08:00
|
|
|
else
|
2024-06-10 14:58:48 +08:00
|
|
|
toast.show(luatr("Old password wrong!"), 5000);
|
2022-03-27 20:00:29 +08:00
|
|
|
}
|