From ff4a0d0d1f9a09cec4facb670830237039ec319b Mon Sep 17 00:00:00 2001 From: Danmei Chen Date: Wed, 24 Apr 2019 12:16:46 +0200 Subject: [PATCH] fix pushnotification --- Classes/LinphoneManager.m | 2 +- Resources/linphonerc | 2 +- Resources/linphonerc-factory | 2 +- Resources/linphonerc~ipad | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Classes/LinphoneManager.m b/Classes/LinphoneManager.m index 5b7b4be74..1650f34c5 100644 --- a/Classes/LinphoneManager.m +++ b/Classes/LinphoneManager.m @@ -2394,7 +2394,7 @@ static int comp_call_state_paused(const LinphoneCall *call, const void *param) { } } - if ([LinphoneManager.instance lpConfigBoolForKey:@"backgroundmode_preference"] && !pushNotifEnabled) { + if ([LinphoneManager.instance lpConfigBoolForKey:@"voip_mode_preference"] && [LinphoneManager.instance lpConfigBoolForKey:@"backgroundmode_preference"] && !pushNotifEnabled) { // Keep this!! Socket VoIP is deprecated after 9.0, but sometimes it's the only way to keep the phone background and receive the call. For example, when there is only local area network. // register keepalive if ([[UIApplication sharedApplication] diff --git a/Resources/linphonerc b/Resources/linphonerc index b17aacd84..292436ca9 100644 --- a/Resources/linphonerc +++ b/Resources/linphonerc @@ -1,7 +1,7 @@ [app] animations_preference=1 autoanswer_notif_preference=1 -backgroundmode_preference=0 +backgroundmode_preference=1 edge_opt_preference=0 enable_log_collect=0 file_transfer_migration_done=1 diff --git a/Resources/linphonerc-factory b/Resources/linphonerc-factory index 23a0868d4..bc44d54e0 100644 --- a/Resources/linphonerc-factory +++ b/Resources/linphonerc-factory @@ -21,7 +21,7 @@ debug_popup_email=linphone-iphone@belledonne-communications.com send_logs_include_linphonerc_and_chathistory=0 #use_phone_number=0 publish_presence=0 -backgroundmode_preference=0 +backgroundmode_preference=1 use_rls_presence=1 accept_early_media=0 diff --git a/Resources/linphonerc~ipad b/Resources/linphonerc~ipad index 54de79c3c..1eaec502d 100644 --- a/Resources/linphonerc~ipad +++ b/Resources/linphonerc~ipad @@ -1,7 +1,7 @@ [app] animations_preference=1 autoanswer_notif_preference=1 -backgroundmode_preference=0 +backgroundmode_preference=1 edge_opt_preference=0 enable_log_collect=0 file_transfer_migration_done=1