更新
This commit is contained in:
@@ -107,12 +107,14 @@ class _MHTWifiPageState extends State<MHTWifiPage> {
|
||||
|
||||
// 导航到下一页
|
||||
if (blueteethBindController.wifiStatus.value != 1) {
|
||||
showConfirmDialog(context, Container(), "未配置网络提示".tr, onConfirm: () {
|
||||
showConfirmDialog(context, Container(), "未配置网络提示".tr, onConfirm: () async {
|
||||
_cleanupResources();
|
||||
await _disconnectDevice();
|
||||
Get.toNamed("/calibrationPage");
|
||||
}, onCancel: () {});
|
||||
} else {
|
||||
_cleanupResources();
|
||||
await _disconnectDevice();
|
||||
Get.toNamed("/calibrationPage");
|
||||
}
|
||||
}
|
||||
@@ -1101,7 +1103,7 @@ class _MHTWifiPageState extends State<MHTWifiPage> {
|
||||
);
|
||||
}
|
||||
|
||||
void _disconnectDevice() async {
|
||||
Future<void> _disconnectDevice() async {
|
||||
try {
|
||||
THapp bledevice = THapp(device: widget.deviceInfo.scanResult.device);
|
||||
await bledevice.disconnect();
|
||||
|
||||
Reference in New Issue
Block a user