From 3d5f8b04474ed6b50c819ca3c8a21b94934ea121 Mon Sep 17 00:00:00 2001 From: Benjamin Reis Date: Wed, 10 Jan 2018 13:48:52 +0100 Subject: [PATCH] enhance proximity sensor support --- Classes/LinphoneManager.m | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Classes/LinphoneManager.m b/Classes/LinphoneManager.m index dfcacb693..22d3a9bb8 100644 --- a/Classes/LinphoneManager.m +++ b/Classes/LinphoneManager.m @@ -989,8 +989,7 @@ static void linphone_iphone_display_status(struct _LinphoneCore *lc, const char if (state == LinphoneCallConnected && !mCallCenter) { /*only register CT call center CB for connected call*/ [self setupGSMInteraction]; - if (!_bluetoothEnabled) - [self setSpeakerEnabled:FALSE]; + [[UIDevice currentDevice] setProximityMonitoringEnabled:!(_speakerEnabled || _bluetoothEnabled)]; } // Post event