logout confirm
Signed-off-by: 21pages <pages21@163.com>
This commit is contained in:
parent
314d7f4387
commit
ebd8903c9b
@ -675,3 +675,22 @@ Future<bool?> verificationCodeDialog(UserPayload? user) async {
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
void logOutConfirmDialog() {
|
||||
gFFI.dialogManager.show((setState, close, context) {
|
||||
submit() {
|
||||
close();
|
||||
gFFI.userModel.logOut();
|
||||
}
|
||||
|
||||
return CustomAlertDialog(
|
||||
content: Text(translate("logout_tip")),
|
||||
actions: [
|
||||
dialogButton(translate("Cancel"), onPressed: close, isOutline: true),
|
||||
dialogButton(translate("OK"), onPressed: submit),
|
||||
],
|
||||
onSubmit: submit,
|
||||
onCancel: close,
|
||||
);
|
||||
});
|
||||
}
|
||||
|
@ -1385,7 +1385,7 @@ class _AccountState extends State<_Account> {
|
||||
() => {
|
||||
gFFI.userModel.userName.value.isEmpty
|
||||
? loginDialog()
|
||||
: gFFI.userModel.logOut()
|
||||
: logOutConfirmDialog()
|
||||
}));
|
||||
}
|
||||
|
||||
@ -1503,7 +1503,7 @@ class _PluginState extends State<_Plugin> {
|
||||
() => {
|
||||
gFFI.userModel.userName.value.isEmpty
|
||||
? loginDialog()
|
||||
: gFFI.userModel.logOut()
|
||||
: logOutConfirmDialog()
|
||||
}));
|
||||
}
|
||||
}
|
||||
|
@ -275,7 +275,7 @@ class _WebMenuState extends State<WebMenu> {
|
||||
if (gFFI.userModel.userName.value.isEmpty) {
|
||||
loginDialog();
|
||||
} else {
|
||||
gFFI.userModel.logOut();
|
||||
logOutConfirmDialog();
|
||||
}
|
||||
}
|
||||
if (value == 'scan') {
|
||||
|
@ -392,7 +392,7 @@ class _SettingsState extends State<SettingsPage> with WidgetsBindingObserver {
|
||||
if (gFFI.userModel.userName.value.isEmpty) {
|
||||
loginDialog();
|
||||
} else {
|
||||
gFFI.userModel.logOut();
|
||||
logOutConfirmDialog();
|
||||
}
|
||||
},
|
||||
),
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", "发起的连接"),
|
||||
("Exit", "退出"),
|
||||
("Open", "打开"),
|
||||
("logout_tip", "确定要退出登录吗?"),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", "Ausgehende Verbindung"),
|
||||
("Exit", "Beenden"),
|
||||
("Open", "Öffnen"),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -71,5 +71,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("resolution_custom_tip", "Custom resolution"),
|
||||
("accept_and_elevate_btn_tooltip", "Accept the connection and elevate UAC permissions."),
|
||||
("clipboard_wait_response_timeout_tip", "Timed out waiting for copy response."),
|
||||
("logout_tip", "Are you sure you want to log out ?")
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", "اتصال خروجی"),
|
||||
("Exit", "خروج"),
|
||||
("Open", "باز کردن"),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", "Conenssioni in uscita"),
|
||||
("Exit", "Esci da RustDesk"),
|
||||
("Open", "Apri RustDesk"),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", "Uitgaande verbinding"),
|
||||
("Exit", "Verlaten"),
|
||||
("Open", "Open"),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", "Исходящее подключение"),
|
||||
("Exit", "Выход"),
|
||||
("Open", "Открыть"),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", "發起的連接"),
|
||||
("Exit", "退出"),
|
||||
("Open", "開啟"),
|
||||
("logout_tip", "確定要退出登錄嗎?"),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
@ -517,5 +517,6 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> =
|
||||
("Outgoing connection", ""),
|
||||
("Exit", ""),
|
||||
("Open", ""),
|
||||
("logout_tip", ""),
|
||||
].iter().cloned().collect();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user