fix:对讲时进入后台关闭链接
This commit is contained in:
parent
eb801de7c3
commit
066aff8fdf
@ -28,17 +28,16 @@ class AppLifecycleObserver extends WidgetsBindingObserver {
|
|||||||
|
|
||||||
void onAppPaused() {
|
void onAppPaused() {
|
||||||
// 处理应用程序进入后台的逻辑
|
// 处理应用程序进入后台的逻辑
|
||||||
print('App has entered the background.');
|
|
||||||
if (StartChartManage().talkStatus.status ==
|
final status = StartChartManage().talkStatus.status;
|
||||||
TalkStatus.passiveCallWaitingAnswer ||
|
|
||||||
StartChartManage().talkStatus.status ==
|
if (status == TalkStatus.passiveCallWaitingAnswer ||
|
||||||
TalkStatus.proactivelyCallWaitingAnswer) {
|
status == TalkStatus.proactivelyCallWaitingAnswer ||
|
||||||
StartChartManage().startTalkHangupMessageTimer();
|
status == TalkStatus.answeredSuccessfully ||
|
||||||
StartChartManage().startTalkRejectMessageTimer();
|
status == TalkStatus.uninitialized) {
|
||||||
// 如果是等待接听时就退出页面
|
StartChartManage().destruction();
|
||||||
Get.back();
|
Get.back();
|
||||||
}
|
}
|
||||||
StartChartManage().destruction();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void onAppResumed() async {
|
void onAppResumed() async {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user