diff --git a/Classes/CallOutgoingView.m b/Classes/CallOutgoingView.m index 97bfeb68f..83a64e8bf 100644 --- a/Classes/CallOutgoingView.m +++ b/Classes/CallOutgoingView.m @@ -120,7 +120,7 @@ static UICompositeViewDescription *compositeDescription = nil; - (IBAction)onDeclineClick:(id)sender { LinphoneCall *call = linphone_core_get_current_call(LC); if (call) { - linphone_call_terminate(call); + [LinphoneManager.instance terminateCall:call]; } } diff --git a/Classes/ChatConversationView.h b/Classes/ChatConversationView.h index 8616983b9..6884b9985 100644 --- a/Classes/ChatConversationView.h +++ b/Classes/ChatConversationView.h @@ -59,6 +59,7 @@ @property(nonatomic) LinphoneChatRoom *chatRoom; @property(nonatomic) LinphoneChatRoomCbs *chatRoomCbs; @property(nonatomic) Boolean markAsRead; +@property(nonatomic) const char *peerAddress; @property (strong, nonatomic) FileDataSource *FileDataSource; diff --git a/Classes/ChatConversationView.m b/Classes/ChatConversationView.m index f1c210dc6..c1534faba 100644 --- a/Classes/ChatConversationView.m +++ b/Classes/ChatConversationView.m @@ -154,10 +154,6 @@ static UICompositeViewDescription *compositeDescription = nil; - (void)viewWillAppear:(BOOL)animated { [super viewWillAppear:animated]; - [NSNotificationCenter.defaultCenter addObserver:self - selector:@selector(applicationWillEnterForeground:) - name:UIApplicationDidBecomeActiveNotification - object:nil]; [NSNotificationCenter.defaultCenter addObserver:self selector:@selector(keyboardWillShow:) name:UIKeyboardWillShowNotification @@ -174,7 +170,14 @@ static UICompositeViewDescription *compositeDescription = nil; selector:@selector(callUpdateEvent:) name:kLinphoneCallUpdate object:nil]; - + [NSNotificationCenter.defaultCenter addObserver:self + selector:@selector(onLinphoneCoreReady:) + name:kLinphoneGlobalStateUpdate + object:nil]; + [NSNotificationCenter.defaultCenter addObserver:self + selector:@selector(didEnterBackground:) + name:UIApplicationDidEnterBackgroundNotification + object:nil]; if ([_imagesArray count] > 0) { [UIView animateWithDuration:0 delay:0 @@ -212,6 +215,11 @@ static UICompositeViewDescription *compositeDescription = nil; PhoneMainView.instance.currentRoom = NULL; } +- (void)didEnterBackground:(NSNotification *)notif { + linphone_chat_room_remove_callbacks(_chatRoom, _chatRoomCbs); + _chatRoomCbs = NULL; +} + - (void)didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation { [super didRotateFromInterfaceOrientation:fromInterfaceOrientation]; composingVisible = !composingVisible; @@ -358,11 +366,19 @@ static UICompositeViewDescription *compositeDescription = nil; } } -- (void)applicationWillEnterForeground:(NSNotification *)notif { - if (_chatRoom && _markAsRead) - [ChatConversationView markAsRead:_chatRoom]; - - _markAsRead = TRUE; +// reload the chatroom after the core starts +- (void)onLinphoneCoreReady:(NSNotification *)notif { + if ((LinphoneGlobalState)[[[notif userInfo] valueForKey:@"state"] integerValue] == LinphoneGlobalOn) { + LinphoneAddress *peerAddr = linphone_core_create_address([LinphoneManager getLc], _peerAddress); + if (peerAddr) { + _chatRoom = linphone_core_get_chat_room([LinphoneManager getLc], peerAddr); + } + [self configureForRoom:self.editing]; + if (_chatRoom && _markAsRead) { + [ChatConversationView markAsRead:_chatRoom]; + } + _markAsRead = TRUE; + } } - (void)callUpdateEvent:(NSNotification *)notif { diff --git a/Classes/ConfigManager.swift b/Classes/ConfigManager.swift index 0b681650c..c3881f217 100644 --- a/Classes/ConfigManager.swift +++ b/Classes/ConfigManager.swift @@ -21,7 +21,7 @@ import Foundation import linphonesw /* -* ConfigManager is a class that manipulates the configuration of the apllication. +* ConfigManager is a class that manipulates the configuration of the application. * There is only one ConfigManager by calling ConfigManager.instance(). */ @objc class ConfigManager: NSObject { diff --git a/Classes/LinphoneAppDelegate.m b/Classes/LinphoneAppDelegate.m index d3873c0da..2a46b7113 100644 --- a/Classes/LinphoneAppDelegate.m +++ b/Classes/LinphoneAppDelegate.m @@ -59,6 +59,16 @@ LOGI(@"%@", NSStringFromSelector(_cmd)); [LinphoneManager.instance enterBackgroundMode]; CallManager.instance.callHandled = @""; + LinphoneCall *call = linphone_core_get_current_call(LC); + + if (!call) { + [LinphoneManager.instance stopLinphoneCore]; + } +} + +- (void)applicationWillEnterForeground:(UIApplication *)application { + [LinphoneManager.instance startLinphoneCore]; + [NSNotificationCenter.defaultCenter postNotificationName:kLinphoneMessageReceived object:nil]; } - (void)applicationWillResignActive:(UIApplication *)application { @@ -152,6 +162,10 @@ LOGI(@"[PushKit] Connecting for push notifications"); self.voipRegistry.desiredPushTypes = [NSSet setWithObject:PKPushTypeVoIP]; + // Register for remote notifications. + LOGI(@"[APNs] register for push notif"); + [[UIApplication sharedApplication] registerForRemoteNotifications]; + [self configureUINotification]; } @@ -279,7 +293,7 @@ [[UIApplication sharedApplication] endBackgroundTask:bgStartId]; }]; - [LinphoneManager.instance startLinphoneCore]; + [LinphoneManager.instance launchLinphoneCore]; LinphoneManager.instance.iapManager.notificationCategory = @"expiry_notification"; // initialize UI [self.window makeKeyAndVisible]; @@ -312,25 +326,6 @@ LinphoneManager.instance.conf = TRUE; linphone_core_terminate_all_calls(LC); [CallManager.instance removeAllCallInfos]; - - // !!! Will be removed after push notification job finished - // destroyLinphoneCore automatically unregister proxies but if we are using - // remote push notifications, we want to continue receiving them - if (LinphoneManager.instance.pushNotificationToken != nil) { - // trick me! setting network reachable to false will avoid sending unregister - const MSList *proxies = linphone_core_get_proxy_config_list(LC); - BOOL pushNotifEnabled = NO; - while (proxies) { - const char *refkey = linphone_proxy_config_get_ref_key(proxies->data); - pushNotifEnabled = pushNotifEnabled || (refkey && strcmp(refkey, "push_notification") == 0); - proxies = proxies->next; - } - // but we only want to hack if at least one proxy config uses remote push.. - if (pushNotifEnabled) { - linphone_core_set_network_reachable(LC, FALSE); - } - } - [LinphoneManager.instance destroyLinphoneCore]; } @@ -572,31 +567,38 @@ - (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken { - LOGI(@"%@ : %@", NSStringFromSelector(_cmd), deviceToken); - [LinphoneManager.instance setPushNotificationToken:deviceToken]; + LOGI(@"[APNs] %@ : %@", NSStringFromSelector(_cmd), deviceToken); + [LinphoneManager.instance setRemoteNotificationToken:deviceToken]; } - (void)application:(UIApplication *)application didFailToRegisterForRemoteNotificationsWithError:(NSError *)error { - LOGI(@"%@ : %@", NSStringFromSelector(_cmd), [error localizedDescription]); - [LinphoneManager.instance setPushNotificationToken:nil]; + LOGI(@"[APNs] %@ : %@", NSStringFromSelector(_cmd), [error localizedDescription]); + [LinphoneManager.instance setRemoteNotificationToken:nil]; } #pragma mark - PushKit Functions - (void)pushRegistry:(PKPushRegistry *)registry didUpdatePushCredentials:(PKPushCredentials *)credentials forType:(PKPushType)type { LOGI(@"[PushKit] credentials updated with voip token: %@", credentials.token); - dispatch_async(dispatch_get_main_queue(), ^{ - [LinphoneManager.instance setPushNotificationToken:credentials.token]; + dispatch_async(dispatch_get_main_queue(), ^{ // TODO PAUL : why? + [LinphoneManager.instance setPushKitToken:credentials.token]; }); } - (void)pushRegistry:(PKPushRegistry *)registry didInvalidatePushTokenForType:(NSString *)type { LOGI(@"[PushKit] Token invalidated"); - dispatch_async(dispatch_get_main_queue(), ^{[LinphoneManager.instance setPushNotificationToken:nil];}); + dispatch_async(dispatch_get_main_queue(), ^{[LinphoneManager.instance setPushKitToken:nil];}); } - (void)processPush:(NSDictionary *)userInfo { LOGI(@"[PushKit] Notification [%p] received with payload : %@", userInfo, userInfo.description); + +// prevent app to crash if pushKit received for msg + if ([userInfo[@"aps"][@"loc-key"] isEqualToString:@"IM_MSG"]) { // TODO PAUL: a supprimer, fix temporaire: le serveur n'enverra plus de pushkit pr les msg + return; + } + [LinphoneManager.instance startLinphoneCore]; + [self configureUINotification]; //to avoid IOS to suspend the app before being able to launch long running task [self processRemoteNotification:userInfo]; @@ -614,6 +616,12 @@ #pragma mark - UNUserNotifications Framework - (void) userNotificationCenter:(UNUserNotificationCenter *)center willPresentNotification:(UNNotification *)notification withCompletionHandler:(void (^)(UNNotificationPresentationOptions))completionHandler { + // If an app extension launch a user notif while app is in fg, it is catch by the app + NSString *category = [[[notification request] content] categoryIdentifier]; + if (category && [category isEqualToString:@"app_active"]) { + return; + } + completionHandler(UNNotificationPresentationOptionAlert | UNNotificationPresentationOptionAlert); } @@ -693,16 +701,19 @@ else [PhoneMainView.instance displayIncomingCall:call]; } else if ([response.notification.request.content.categoryIdentifier isEqual:@"msg_cat"]) { - NSString *peer_address = [response.notification.request.content.userInfo objectForKey:@"peer_addr"]; - NSString *local_address = [response.notification.request.content.userInfo objectForKey:@"local_addr"]; - LinphoneAddress *peer = linphone_address_new(peer_address.UTF8String); - LinphoneAddress *local = linphone_address_new(local_address.UTF8String); - LinphoneChatRoom *room = linphone_core_find_chat_room(LC, peer, local); - if (room) { - [PhoneMainView.instance goToChatRoom:room]; - return; - } - [PhoneMainView.instance changeCurrentView:ChatsListView.compositeViewDescription]; + // prevent to go to chat room view when removing the notif + if (![response.actionIdentifier isEqualToString:@"com.apple.UNNotificationDismissActionIdentifier"]) { + NSString *peer_address = [response.notification.request.content.userInfo objectForKey:@"peer_addr"]; + NSString *local_address = [response.notification.request.content.userInfo objectForKey:@"local_addr"]; + LinphoneAddress *peer = linphone_address_new(peer_address.UTF8String); + LinphoneAddress *local = linphone_address_new(local_address.UTF8String); + LinphoneChatRoom *room = linphone_core_find_chat_room(LC, peer, local); + if (room) { + [PhoneMainView.instance goToChatRoom:room]; + return; + } + [PhoneMainView.instance changeCurrentView:ChatsListView.compositeViewDescription]; + } } else if ([response.notification.request.content.categoryIdentifier isEqual:@"video_request"]) { [PhoneMainView.instance changeCurrentView:CallView.compositeViewDescription]; NSTimer *videoDismissTimer = nil; @@ -918,7 +929,7 @@ object:nil]; linphone_core_set_provisioning_uri(LC, [configURL UTF8String]); [LinphoneManager.instance destroyLinphoneCore]; - [LinphoneManager.instance startLinphoneCore]; + [LinphoneManager.instance launchLinphoneCore]; [LinphoneManager.instance.fastAddressBook fetchContactsInBackGroundThread]; } diff --git a/Classes/LinphoneManager.h b/Classes/LinphoneManager.h index 899935f3a..faa90e845 100644 --- a/Classes/LinphoneManager.h +++ b/Classes/LinphoneManager.h @@ -60,6 +60,8 @@ extern NSString *const kLinphoneFileTransferRecvUpdate; extern NSString *const kLinphoneQRCodeFound; extern NSString *const kLinphoneChatCreateViewChange; +extern NSString *const kLinphoneMsgNotificationGroupId; + typedef enum _NetworkType { network_none = 0, network_2g, @@ -104,6 +106,7 @@ typedef struct _LinphoneManagerSounds { + (void)instanceRelease; #endif + (LinphoneCore*) getLc; ++ (BOOL)isLcInitialized; + (BOOL)runningOnIpad; + (BOOL)isNotIphone3G; + (NSString *)getPreferenceForCodec: (const char*) name withRate: (int) rate; @@ -114,12 +117,15 @@ typedef struct _LinphoneManagerSounds { - (void)playMessageSound; - (void)resetLinphoneCore; -- (void)startLinphoneCore; +- (void)launchLinphoneCore; - (void)destroyLinphoneCore; +- (void)startLinphoneCore; +- (void)stopLinphoneCore; - (BOOL)resignActive; - (void)becomeActive; - (BOOL)enterBackgroundMode; - (void)addPushCallId:(NSString*) callid; +- (void)configurePushTokenForProxyConfigs; - (void)configurePushTokenForProxyConfig: (LinphoneProxyConfig*)cfg; - (BOOL)popPushCallID:(NSString*) callId; - (void)acceptCallForCallId:(NSString*)callid; @@ -137,9 +143,13 @@ typedef struct _LinphoneManagerSounds { + (NSString *)documentFile:(NSString *)file; + (NSString*)dataFile:(NSString*)file; + (NSString*)cacheDirectory; +// migration ++ (NSString *)oldPreferenceFile:(NSString *)file; ++ (NSString *)oldDataFile:(NSString *)file; - (void)send:(NSString *)replyText toChatRoom:(LinphoneChatRoom *)room; - (void)call:(const LinphoneAddress *)address; +- (void)terminateCall:(LinphoneCall *)call; +(id)getMessageAppDataForKey:(NSString*)key inMessage:(LinphoneChatMessage*)msg; +(void)setValueInMessageAppData:(id)value forKey:(NSString*)key inMessage:(LinphoneChatMessage*)msg; @@ -195,7 +205,8 @@ typedef struct _LinphoneManagerSounds { @property (readonly) const char* backCamId; @property(strong, nonatomic) NSString *SSID; @property (readonly) sqlite3* database; -@property(nonatomic, strong) NSData *pushNotificationToken; +@property(nonatomic, strong) NSData *pushKitToken; +@property(nonatomic, strong) NSData *remoteNotificationToken; @property (readonly) LinphoneManagerSounds sounds; @property (readonly) NSMutableArray *logs; @property (nonatomic, assign) BOOL bluetoothAvailable; @@ -210,6 +221,7 @@ typedef struct _LinphoneManagerSounds { @property NSDictionary *pushDict; @property(strong, nonatomic) OrderedDictionary *linphoneManagerAddressBookMap; @property (nonatomic, assign) BOOL contactsUpdated; +@property (nonatomic, assign) BOOL canConfigurePushTokenForProxyConfigs; // used to register at the right time when receiving push notif tokens @property UIImage *avatar; @end diff --git a/Classes/LinphoneManager.m b/Classes/LinphoneManager.m index acb17702c..420c29795 100644 --- a/Classes/LinphoneManager.m +++ b/Classes/LinphoneManager.m @@ -75,6 +75,8 @@ NSString *const kLinphoneFileTransferRecvUpdate = @"LinphoneFileTransferRecvUpda NSString *const kLinphoneQRCodeFound = @"LinphoneQRCodeFound"; NSString *const kLinphoneChatCreateViewChange = @"LinphoneChatCreateViewChange"; +NSString *const kLinphoneMsgNotificationGroupId = @"group.org.linphone.phone.msgNotification"; + const int kLinphoneAudioVbrCodecDefaultBitrate = 36; /*you can override this from linphonerc or linphonerc-factory*/ extern void libmsamr_init(MSFactory *factory); @@ -240,6 +242,7 @@ struct codec_name_pref_table codec_pref_table[] = {{"speex", 8000, "speex_8k_pre _pushDict = [[NSMutableDictionary alloc] init]; _database = NULL; _conf = FALSE; + _canConfigurePushTokenForProxyConfigs = FALSE; _fileTransferDelegates = [[NSMutableArray alloc] init]; _linphoneManagerAddressBookMap = [[OrderedDictionary alloc] init]; pushCallIDs = [[NSMutableArray alloc] init]; @@ -249,6 +252,8 @@ struct codec_name_pref_table codec_pref_table[] = {{"speex", 8000, "speex_8k_pre [self copyDefaultSettings]; [self overrideDefaultSettings]; + [self lpConfigSetString:[LinphoneManager dataFile:@"linphone.db"] forKey:@"uri" inSection:@"storage"]; + [self lpConfigSetString:[LinphoneManager dataFile:@"x3dh.c25519.sqlite3"] forKey:@"x3dh_db_path" inSection:@"lime"]; // set default values for first boot if ([self lpConfigStringForKey:@"debugenable_preference"] == nil) { #ifdef DEBUG @@ -494,6 +499,13 @@ static void migrateWizardToAssistant(const char *entry, void *user_data) { return theLinphoneCore; } ++ (BOOL)isLcInitialized { + if (theLinphoneCore == nil) { + return NO; + } + return YES; +} + #pragma mark Debug functions + (void)dumpLcConfig { @@ -840,6 +852,11 @@ static void linphone_iphone_popup_password_request(LinphoneCore *lc, LinphoneAut return; } + // don't show msg notif when app in bg during a call : msgNotificationService extension will show a notif + if ([UIApplication sharedApplication].applicationState == UIApplicationStateBackground) { + return; + } + // Create a new notification if (floor(NSFoundationVersionNumber) <= NSFoundationVersionNumber_iOS_9_x_Max) { NSArray *actions; @@ -1200,14 +1217,7 @@ static void linphone_iphone_is_composing_received(LinphoneCore *lc, LinphoneChat // scheduling loop - (void)iterate { - UIBackgroundTaskIdentifier coreIterateTaskId = 0; - coreIterateTaskId = [[UIApplication sharedApplication] beginBackgroundTaskWithExpirationHandler:^{ - LOGW(@"Background task for core iteration launching expired."); - [[UIApplication sharedApplication] endBackgroundTask:coreIterateTaskId]; - }]; linphone_core_iterate(theLinphoneCore); - if (coreIterateTaskId != UIBackgroundTaskInvalid) - [[UIApplication sharedApplication] endBackgroundTask:coreIterateTaskId]; } /** Should be called once per linphone_core_new() */ @@ -1288,7 +1298,7 @@ static void linphone_iphone_is_composing_received(LinphoneCore *lc, LinphoneChat static BOOL libStarted = FALSE; -- (void)startLinphoneCore { +- (void)launchLinphoneCore { if (libStarted) { LOGE(@"Liblinphone is already initialized!"); @@ -1396,6 +1406,17 @@ void popup_link_account_cb(LinphoneAccountCreator *creator, LinphoneAccountCreat } } +- (void)startLinphoneCore { + linphone_core_start([LinphoneManager getLc]); + mIterateTimer = + [NSTimer scheduledTimerWithTimeInterval:0.02 target:self selector:@selector(iterate) userInfo:nil repeats:YES]; +} + +- (void)stopLinphoneCore { + [mIterateTimer invalidate]; + linphone_core_stop([LinphoneManager getLc]); +} + - (void)createLinphoneCore { [self migrationAllPre]; if (theLinphoneCore != nil) { @@ -1439,7 +1460,7 @@ void popup_link_account_cb(LinphoneAccountCreator *creator, LinphoneAccountCreat linphone_core_cbs_set_qrcode_found(cbs, linphone_iphone_qr_code_found); linphone_core_cbs_set_user_data(cbs, (__bridge void *)(self)); - theLinphoneCore = linphone_factory_create_core_with_config_3(factory, _configDb, NULL); + theLinphoneCore = linphone_factory_create_shared_core_with_config(factory, _configDb, NULL, [kLinphoneMsgNotificationGroupId UTF8String], true); linphone_core_add_callbacks(theLinphoneCore, cbs); [CallManager.instance setCoreWithCore:theLinphoneCore]; @@ -1812,25 +1833,27 @@ static int comp_call_state_paused(const LinphoneCall *call, const void *param) { } - (void)migrateImportantFiles { - if ([LinphoneManager copyFile:[LinphoneManager documentFile:@"linphonerc"] destination:[LinphoneManager preferenceFile:@"linphonerc"] override:TRUE ignore:TRUE]) - [NSFileManager.defaultManager - removeItemAtPath:[LinphoneManager documentFile:@"linphonerc"] - error:nil]; - - if ([LinphoneManager copyFile:[LinphoneManager documentFile:@"linphone_chats.db"] destination:[LinphoneManager dataFile:@"linphone_chats.db"] override:TRUE ignore:TRUE]) - [NSFileManager.defaultManager - removeItemAtPath:[LinphoneManager documentFile:@"linphone_chats.db"] - error:nil]; - - if ([LinphoneManager copyFile:[LinphoneManager documentFile:@"zrtp_secrets"] destination:[LinphoneManager dataFile:@"zrtp_secrets"] override:TRUE ignore:TRUE]) - [NSFileManager.defaultManager - removeItemAtPath:[LinphoneManager documentFile:@"zrtp_secrets"] - error:nil]; - - if ([LinphoneManager copyFile:[LinphoneManager documentFile:@"zrtp_secrets.bkp"] destination:[LinphoneManager dataFile:@"zrtp_secrets.bkp"] override:TRUE ignore:TRUE]) - [NSFileManager.defaultManager - removeItemAtPath:[LinphoneManager documentFile:@"zrtp_secrets.bkp"] - error:nil]; + if ([LinphoneManager copyFile:[LinphoneManager oldPreferenceFile:@"linphonerc"] destination:[LinphoneManager preferenceFile:@"linphonerc"] override:TRUE ignore:TRUE]) { + [NSFileManager.defaultManager + removeItemAtPath:[LinphoneManager oldPreferenceFile:@"linphonerc"] + error:nil]; + } else if ([LinphoneManager copyFile:[LinphoneManager documentFile:@"linphonerc"] destination:[LinphoneManager preferenceFile:@"linphonerc"] override:TRUE ignore:TRUE]) { + [NSFileManager.defaultManager + removeItemAtPath:[LinphoneManager documentFile:@"linphonerc"] + error:nil]; + } + + if ([LinphoneManager copyFile:[LinphoneManager oldDataFile:@"linphone.db"] destination:[LinphoneManager dataFile:@"linphone.db"] override:TRUE ignore:TRUE]) { + [NSFileManager.defaultManager + removeItemAtPath:[LinphoneManager oldDataFile:@"linphone.db"] + error:nil]; + } + + if ([LinphoneManager copyFile:[LinphoneManager oldDataFile:@"x3dh.c25519.sqlite3"] destination:[LinphoneManager dataFile:@"x3dh.c25519.sqlite3"] override:TRUE ignore:TRUE]) { + [NSFileManager.defaultManager + removeItemAtPath:[LinphoneManager oldDataFile:@"x3dh.c25519.sqlite3"] + error:nil]; + } } - (void)renameDefaultSettings { @@ -1869,8 +1892,7 @@ static int comp_call_state_paused(const LinphoneCall *call, const void *param) { if (IPAD && [[NSFileManager defaultManager] fileExistsAtPath:factoryIpad]) { factory = factoryIpad; } - NSString *confiFileName = [LinphoneManager preferenceFile:@"linphonerc"]; - _configDb = lp_config_new_with_factory([confiFileName UTF8String], [factory UTF8String]); + _configDb = linphone_config_new_for_shared_core(kLinphoneMsgNotificationGroupId.UTF8String, @"linphonerc".UTF8String, factory.UTF8String); } #pragma mark - Audio route Functions @@ -1981,43 +2003,91 @@ static int comp_call_state_paused(const LinphoneCall *call, const void *param) { [CallManager.instance startCallWithAddr:iaddr isSas:FALSE]; } +- (void)terminateCall:(LinphoneCall *)call {// TODO PAUL : needs to be tested with CallKit changes + linphone_call_terminate(call); + if ([UIApplication sharedApplication].applicationState == UIApplicationStateBackground) { + [LinphoneManager.instance stopLinphoneCore]; + } +} + #pragma mark - Property Functions -- (void)setPushNotificationToken:(NSData *)apushNotificationToken { - if (apushNotificationToken == _pushNotificationToken) { +- (void)setPushKitToken:(NSData *)pushKitToken { + if (pushKitToken == _pushKitToken) { return; } - _pushNotificationToken = apushNotificationToken; + _pushKitToken = pushKitToken; + + [self configurePushTokenForProxyConfigs]; +} + +- (void)setRemoteNotificationToken:(NSData *)remoteNotificationToken { + if (remoteNotificationToken == _remoteNotificationToken) { + return; + } + _remoteNotificationToken = remoteNotificationToken; + + [self configurePushTokenForProxyConfigs]; +} + +- (void)configurePushTokenForProxyConfigs { + // we register only when the second token is set + if (_canConfigurePushTokenForProxyConfigs) { + @try { + const MSList *proxies = linphone_core_get_proxy_config_list(LC); + while (proxies) { + [self configurePushTokenForProxyConfig:proxies->data]; + proxies = proxies->next; + } + } @catch (NSException* e) { + LOGW(@"%s: linphone core not ready yet, ignoring push token", __FUNCTION__); + } + } else { + _canConfigurePushTokenForProxyConfigs = YES; + } - @try { - const MSList *proxies = linphone_core_get_proxy_config_list(LC); - while (proxies) { - [self configurePushTokenForProxyConfig:proxies->data]; - proxies = proxies->next; - } - } @catch (NSException* e) { - LOGW(@"%s: linphone core not ready yet, ignoring push token", __FUNCTION__); - } } - (void)configurePushTokenForProxyConfig:(LinphoneProxyConfig *)proxyCfg { linphone_proxy_config_edit(proxyCfg); - NSData *tokenData = _pushNotificationToken; + NSData *remoteTokenData = _remoteNotificationToken; + NSData *PKTokenData = _pushKitToken; BOOL pushNotifEnabled = linphone_proxy_config_is_push_notification_allowed(proxyCfg); - if (tokenData != nil && pushNotifEnabled) { - const unsigned char *tokenBuffer = [tokenData bytes]; - NSMutableString *tokenString = [NSMutableString stringWithCapacity:[tokenData length] * 2]; - for (int i = 0; i < [tokenData length]; ++i) { - [tokenString appendFormat:@"%02X", (unsigned int)tokenBuffer[i]]; + if ((remoteTokenData != nil || PKTokenData != nil) && pushNotifEnabled) { + + const unsigned char *remoteTokenBuffer = [remoteTokenData bytes]; + NSMutableString *remoteTokenString = [NSMutableString stringWithCapacity:[remoteTokenData length] * 2]; + for (int i = 0; i < [PKTokenData length]; ++i) { + [remoteTokenString appendFormat:@"%02X", (unsigned int)remoteTokenBuffer[i]]; } + + const unsigned char *PKTokenBuffer = [PKTokenData bytes]; + NSMutableString *PKTokenString = [NSMutableString stringWithCapacity:[PKTokenData length] * 2]; + for (int i = 0; i < [PKTokenData length]; ++i) { + [PKTokenString appendFormat:@"%02X", (unsigned int)PKTokenBuffer[i]]; + } + + NSString *token; + NSString *services; + if (remoteTokenString && PKTokenString) { + token = [NSString stringWithFormat:@"%@:remote&%@:voip", remoteTokenString, PKTokenString]; + services = @"remote&voip"; + } else if (remoteTokenString) { + token = [NSString stringWithFormat:@"%@:remote", remoteTokenString]; + services = @"remote"; + } else { + token = [NSString stringWithFormat:@"%@:voip", PKTokenString]; + services = @"voip"; + } + // NSLocalizedString(@"IC_MSG", nil); // Fake for genstrings // NSLocalizedString(@"IM_MSG", nil); // Fake for genstrings // NSLocalizedString(@"IM_FULLMSG", nil); // Fake for genstrings #ifdef DEBUG -#define APPMODE_SUFFIX @"dev" +#define APPMODE_SUFFIX @".dev" #else -#define APPMODE_SUFFIX @"prod" +#define APPMODE_SUFFIX @"" #endif NSString *ring = ([LinphoneManager bundleFile:[self lpConfigStringForKey:@"local_ring" inSection:@"sound"].lastPathComponent] @@ -2031,13 +2101,13 @@ static int comp_call_state_paused(const LinphoneCall *call, const void *param) { timeout = @""; } - NSString *params = [NSString - stringWithFormat:@"app-id=%@.voip.%@;pn-type=apple;pn-tok=%@;pn-msg-str=IM_MSG;pn-call-str=IC_MSG;pn-" - @"call-snd=%@;pn-msg-snd=msg.caf%@;pn-silent=1", - [[NSBundle mainBundle] bundleIdentifier], APPMODE_SUFFIX, tokenString, ring, timeout]; - + NSString *params = [NSString + stringWithFormat:@"pn-provider=apns%@;pn-prid=%@;pn-param=ABCD1234.%@.%@;pn-msg-str=IM_MSG;pn-call-str=IC_MSG;pn-" + @"call-snd=%@;pn-msg-snd=msg.caf%@;pn-silent=1", + APPMODE_SUFFIX, token, [[NSBundle mainBundle] bundleIdentifier], services, ring, timeout]; + // TODO PAUL : do we need the team id? LOGI(@"Proxy config %s configured for push notifications with contact: %@", - linphone_proxy_config_get_identity(proxyCfg), params); + linphone_proxy_config_get_identity(proxyCfg), params); linphone_proxy_config_set_contact_uri_parameters(proxyCfg, [params UTF8String]); linphone_proxy_config_set_contact_parameters(proxyCfg, NULL); } else { @@ -2072,45 +2142,22 @@ static int comp_call_state_paused(const LinphoneCall *call, const void *param) { return [documentsPath stringByAppendingPathComponent:file]; } +// TODO PAUL : fonctions a enlever + (NSString *)preferenceFile:(NSString *)file { - NSArray *paths = NSSearchPathForDirectoriesInDomains(NSLibraryDirectory, NSUserDomainMask, YES); - NSString *writablePath = [paths objectAtIndex:0]; - NSString *fullPath = [writablePath stringByAppendingString:@"/Preferences/linphone/"]; - if (![[NSFileManager defaultManager] fileExistsAtPath:fullPath]) { - NSError *error; - LOGI(@"Preference path %@ does not exist, creating it.",fullPath); - if (![[NSFileManager defaultManager] createDirectoryAtPath:fullPath - withIntermediateDirectories:YES - attributes:nil - error:&error]) { - LOGE(@"Create preference path directory error: %@",error.description); - } - } - + LinphoneFactory *factory = linphone_factory_get(); + NSString *fullPath = [NSString stringWithUTF8String:linphone_factory_get_config_path(factory, kLinphoneMsgNotificationGroupId.UTF8String)]; return [fullPath stringByAppendingPathComponent:file]; } + (NSString *)dataFile:(NSString *)file { - NSArray *paths = NSSearchPathForDirectoriesInDomains(NSApplicationSupportDirectory, NSUserDomainMask, YES); - NSString *writablePath = [paths objectAtIndex:0]; - NSString *fullPath = [writablePath stringByAppendingString:@"/linphone/"]; - if (![[NSFileManager defaultManager] fileExistsAtPath:fullPath]) { - NSError *error; - LOGI(@"Data path %@ does not exist, creating it.",fullPath); - if (![[NSFileManager defaultManager] createDirectoryAtPath:fullPath - withIntermediateDirectories:YES - attributes:nil - error:&error]) { - LOGE(@"Create data path directory error: %@",error.description); - } - } - + LinphoneFactory *factory = linphone_factory_get(); + NSString *fullPath = [NSString stringWithUTF8String:linphone_factory_get_data_path(factory, kLinphoneMsgNotificationGroupId.UTF8String)]; return [fullPath stringByAppendingPathComponent:file]; } + (NSString *)cacheDirectory { - NSArray *paths = NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES); - NSString *cachePath = [paths objectAtIndex:0]; + LinphoneFactory *factory = linphone_factory_get(); + NSString *cachePath = [NSString stringWithUTF8String:linphone_factory_get_download_path(factory, kLinphoneMsgNotificationGroupId.UTF8String)]; BOOL isDir = NO; NSError *error; // cache directory must be created if not existing @@ -2123,6 +2170,20 @@ static int comp_call_state_paused(const LinphoneCall *call, const void *param) { return cachePath; } ++ (NSString *)oldPreferenceFile:(NSString *)file { + // migration + LinphoneFactory *factory = linphone_factory_get(); + NSString *fullPath = [NSString stringWithUTF8String:linphone_factory_get_config_path(factory, nil)]; + return [fullPath stringByAppendingPathComponent:file]; +} + ++ (NSString *)oldDataFile:(NSString *)file { + // migration + LinphoneFactory *factory = linphone_factory_get(); + NSString *fullPath = [NSString stringWithUTF8String:linphone_factory_get_data_path(factory, nil)]; + return [fullPath stringByAppendingPathComponent:file]; +} + + (int)unreadMessageCount { int count = 0; const MSList *rooms = linphone_core_get_chat_rooms(LC); diff --git a/Classes/LinphoneUI/UIHangUpButton.m b/Classes/LinphoneUI/UIHangUpButton.m index 3d1b48914..6368fcb6d 100644 --- a/Classes/LinphoneUI/UIHangUpButton.m +++ b/Classes/LinphoneUI/UIHangUpButton.m @@ -97,11 +97,11 @@ LinphoneManager.instance.conf = TRUE; linphone_core_terminate_conference(LC); } else if (currentcall != NULL) { - linphone_call_terminate(currentcall); + [LinphoneManager.instance terminateCall:currentcall]; } else { const MSList *calls = linphone_core_get_calls(LC); if (bctbx_list_size(calls) == 1) { // Only one call - linphone_call_terminate((LinphoneCall *)(calls->data)); + [LinphoneManager.instance terminateCall:(LinphoneCall *)(calls->data)]; } } } diff --git a/Classes/PhoneMainView.m b/Classes/PhoneMainView.m index e558042ab..b2a23f6e7 100644 --- a/Classes/PhoneMainView.m +++ b/Classes/PhoneMainView.m @@ -422,11 +422,17 @@ static RootViewManager *rootViewManagerInstance = nil; case LinphoneCallOutgoingProgress: { break; } + case LinphoneCallReleased: + if ([UIApplication sharedApplication].applicationState == UIApplicationStateBackground) { + dispatch_async(dispatch_get_main_queue(), ^{ + [LinphoneManager.instance stopLinphoneCore]; + }); + } + break; case LinphoneCallOutgoingRinging: case LinphoneCallPaused: case LinphoneCallPausing: case LinphoneCallRefered: - case LinphoneCallReleased: break; case LinphoneCallResuming: { break; @@ -815,7 +821,7 @@ static RootViewManager *rootViewManagerInstance = nil; } - (void)incomingCallDeclined:(LinphoneCall *)call { - linphone_call_terminate(call); + [LinphoneManager.instance terminateCall:call]; } #pragma mark - Chat room Functions @@ -907,6 +913,7 @@ static RootViewManager *rootViewManagerInstance = nil; if (view.chatRoom != cr) [view clearMessageView]; view.chatRoom = cr; + view.peerAddress = linphone_address_as_string(linphone_chat_room_get_peer_address(cr)); self.currentRoom = view.chatRoom; if (PhoneMainView.instance.currentView == view.compositeViewDescription) [view configureForRoom:FALSE]; diff --git a/Classes/ProviderDelegate.swift b/Classes/ProviderDelegate.swift index 8e9aef7b5..9f293d20a 100644 --- a/Classes/ProviderDelegate.swift +++ b/Classes/ProviderDelegate.swift @@ -146,7 +146,7 @@ extension ProviderDelegate: CXProviderDelegate { let call = CallManager.instance().callByCallId(callId: callId) if (call != nil) { do { - try call!.terminate() + try call!.terminate() // TODO PAUL } catch { Log.directLog(BCTBX_LOG_ERROR, text: "CallKit: Call ended \(uuid) failed because \(error)") } diff --git a/Classes/SideMenuTableView.m b/Classes/SideMenuTableView.m index 631305de8..16fe963b6 100644 --- a/Classes/SideMenuTableView.m +++ b/Classes/SideMenuTableView.m @@ -127,7 +127,9 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { UITableViewCell *cell = [[UITableViewCell alloc] init]; - if (indexPath.section == 0) { + + // isLcInitialized called here because this is called when going in bg after LC destroy + if (indexPath.section == 0 && [LinphoneManager isLcInitialized]) { // do not display default account here, it is already in header view int idx = linphone_core_get_default_proxy_config(LC) @@ -147,7 +149,7 @@ cell.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"color_G.png"]]; } else { SideMenuEntry *entry = [_sideMenuEntries objectAtIndex:indexPath.row]; - cell.imageView.image = entry->img; + cell.imageView.image = entry->img; cell.textLabel.text = entry->title; } return cell; diff --git a/Classes/Utils/InAppSettingsKit/Controllers/IASKAppSettingsViewController.m b/Classes/Utils/InAppSettingsKit/Controllers/IASKAppSettingsViewController.m index ec99769a9..739ef33af 100755 --- a/Classes/Utils/InAppSettingsKit/Controllers/IASKAppSettingsViewController.m +++ b/Classes/Utils/InAppSettingsKit/Controllers/IASKAppSettingsViewController.m @@ -222,7 +222,7 @@ CGRect IASKCGRectSwap(CGRect rect); [super viewDidAppear:animated]; NSNotificationCenter *dc = [NSNotificationCenter defaultCenter]; - IASK_IF_IOS4_OR_GREATER([dc addObserver:self selector:@selector(synchronizeSettings) name:UIApplicationDidEnterBackgroundNotification object:[UIApplication sharedApplication]];); + IASK_IF_IOS4_OR_GREATER([dc addObserver:self selector:@selector(synchronizeSettings) name:UIApplicationWillResignActiveNotification object:[UIApplication sharedApplication]];); IASK_IF_IOS4_OR_GREATER([dc addObserver:self selector:@selector(reload) name:UIApplicationWillEnterForegroundNotification object:[UIApplication sharedApplication]];); [dc addObserver:self selector:@selector(synchronizeSettings) name:UIApplicationWillTerminateNotification object:[UIApplication sharedApplication]]; } diff --git a/Classes/Utils/Log.m b/Classes/Utils/Log.m index 43c69275b..de43ec33a 100644 --- a/Classes/Utils/Log.m +++ b/Classes/Utils/Log.m @@ -30,22 +30,6 @@ #define FILE_SIZE 17 #define DOMAIN_SIZE 3 -+ (NSString *)cacheDirectory { - NSArray *paths = NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES); - NSString *cachePath = [paths objectAtIndex:0]; - BOOL isDir = NO; - NSError *error; - // cache directory must be created if not existing - if (![[NSFileManager defaultManager] fileExistsAtPath:cachePath isDirectory:&isDir] && isDir == NO) { - if (![[NSFileManager defaultManager] createDirectoryAtPath:cachePath - withIntermediateDirectories:NO - attributes:nil - error:&error]) { - LOGE(@"Could not create cache directory: %@", error); - } - } - return cachePath; -} + (void)log:(OrtpLogLevel)severity file:(const char *)file line:(int)line format:(NSString *)format, ... { va_list args; @@ -64,7 +48,7 @@ asl_add_log_file(NULL, STDERR_FILENO); stderrInUse = YES; } - linphone_core_set_log_collection_path([self cacheDirectory].UTF8String); + linphone_core_set_log_collection_path([LinphoneManager cacheDirectory].UTF8String); // TODO PAUL : code de migration des logs? linphone_core_set_log_handler(linphone_iphone_log_handler); linphone_core_enable_log_collection(enabled); if (level == 0) { diff --git a/Podfile b/Podfile index 0002c3268..96cbfdea8 100644 --- a/Podfile +++ b/Podfile @@ -6,10 +6,10 @@ source "https://github.com/CocoaPods/Specs.git" def basic_pods if ENV['PODFILE_PATH'].nil? pod 'linphone-sdk/basic-frameworks', '~> 4.4.0-alpha' - else - pod 'linphone-sdk/basic-frameworks', :path => ENV['PODFILE_PATH'] # loacl sdk + else + pod 'linphone-sdk/basic-frameworks', :path => ENV['PODFILE_PATH'] # local sdk end - + crashlythics end @@ -17,9 +17,9 @@ def ext_pods if ENV['PODFILE_PATH'].nil? pod 'linphone-sdk/app-extension-swift', '~> 4.4.0-alpha' else - pod 'linphone-sdk/app-extension-swift', :path => ENV['PODFILE_PATH'] # loacl sdk + pod 'linphone-sdk/app-extension-swift', :path => ENV['PODFILE_PATH'] # local sdk end - + crashlythics end @@ -48,6 +48,24 @@ target 'linphoneExtension' do end +target 'msgNotificationService' do + # Uncomment the next line if you're using Swift or would like to use dynamic frameworks + use_frameworks! + + # Pods for messagesNotification + ext_pods + +end + +target 'msgNotificationContent' do + # Uncomment the next line if you're using Swift or would like to use dynamic frameworks + use_frameworks! + + # Pods for messagesNotification + ext_pods + +end + post_install do |installer| # Get the version of linphone-sdk installer.pod_targets.each do |target| diff --git a/linphone.entitlements b/linphone.entitlements index 1497a8e9e..a9bc9d575 100644 --- a/linphone.entitlements +++ b/linphone.entitlements @@ -24,6 +24,7 @@ group.org.linphone.phone.linphoneExtension group.belledonne-communications.linphone.widget + group.org.linphone.phone.msgNotification diff --git a/linphone.xcodeproj/project.pbxproj b/linphone.xcodeproj/project.pbxproj index 357fa36b5..2c72b275a 100644 --- a/linphone.xcodeproj/project.pbxproj +++ b/linphone.xcodeproj/project.pbxproj @@ -56,6 +56,7 @@ 340751E7150F38FD00B89C47 /* UIVideoButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 340751E6150F38FD00B89C47 /* UIVideoButton.m */; }; 34216F401547EBCD00EA9777 /* VideoZoomHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 34216F3F1547EBCD00EA9777 /* VideoZoomHandler.m */; }; 344ABDF114850AE9007420B6 /* libc++.1.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 344ABDEF14850AE9007420B6 /* libc++.1.dylib */; settings = {ATTRIBUTES = (Weak, ); }; }; + 369CCF81C921CD7C4E49A637 /* Pods_msgNotificationContent.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 82E9DEDA2A78C6DBBD1A54DB /* Pods_msgNotificationContent.framework */; }; 3C4CCF18D4DA173FC144654A /* Pods_linphoneExtension.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BEBE8FB918176C388C01CFF7 /* Pods_linphoneExtension.framework */; }; 570742581D5A0691004B9C84 /* ShopView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 570742561D5A0691004B9C84 /* ShopView.xib */; }; 570742611D5A09B8004B9C84 /* ShopView.m in Sources */ = {isa = PBXBuildFile; fileRef = 5707425F1D5A09B8004B9C84 /* ShopView.m */; }; @@ -126,7 +127,7 @@ 63130FB21C1ED06900371918 /* SideMenuView~ipad.xib in Resources */ = {isa = PBXBuildFile; fileRef = 63130FB01C1ED06900371918 /* SideMenuView~ipad.xib */; }; 631348301B6F7B6600C6BDCB /* UIRoundBorderedButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 6313482F1B6F7B6600C6BDCB /* UIRoundBorderedButton.m */; }; 63177FBF1C86E68C00ADE58D /* CoreVideo.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22276E8613C73D8A00210156 /* CoreVideo.framework */; }; - 6334DDFA1BBAC97C00631900 /* libsqlite3.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = D32B6E2E15A5C0AC0033019F /* libsqlite3.dylib */; }; + 6334DDFA1BBAC97C00631900 /* libsqlite3.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = D32B6E2E15A5C0AC0033019F /* libsqlite3.dylib */; settings = {ATTRIBUTES = (Required, ); }; }; 633671611BCBAAD200BFCBDE /* ChatConversationCreateView.m in Sources */ = {isa = PBXBuildFile; fileRef = 6336715F1BCBAAD200BFCBDE /* ChatConversationCreateView.m */; }; 633756391B67BAF400E21BAD /* SideMenuTableView.m in Sources */ = {isa = PBXBuildFile; fileRef = 633756381B67BAF400E21BAD /* SideMenuTableView.m */; }; 633756451B67D2B200E21BAD /* SideMenuView.m in Sources */ = {isa = PBXBuildFile; fileRef = 633756431B67D2B100E21BAD /* SideMenuView.m */; }; @@ -668,6 +669,7 @@ 8CF25D961F9F336100BEA0C1 /* check_unselected.png in Resources */ = {isa = PBXBuildFile; fileRef = 8CF25D941F9F336100BEA0C1 /* check_unselected.png */; }; 8CF25D9D1F9F76BD00BEA0C1 /* chat_group_informations.png in Resources */ = {isa = PBXBuildFile; fileRef = 8CF25D9B1F9F76BC00BEA0C1 /* chat_group_informations.png */; }; 8CF25D9E1F9F76BD00BEA0C1 /* chat_group_informations@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 8CF25D9C1F9F76BD00BEA0C1 /* chat_group_informations@2x.png */; }; + 93566413F75DA69D2811A716 /* Pods_msgNotificationService.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6F30EA7BEA39DA427CE0754E /* Pods_msgNotificationService.framework */; }; A634ABAFCB39B6AAE4CA991D /* Pods_linphone.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 65CEDD144CABFAA70A29AF27 /* Pods_linphone.framework */; }; C90FAA7915AF54E6002091CB /* HistoryDetailsView.m in Sources */ = {isa = PBXBuildFile; fileRef = C90FAA7715AF54E6002091CB /* HistoryDetailsView.m */; }; CF15F21E20E4F9A3008B1DE6 /* UIImageViewDeletable.m in Sources */ = {isa = PBXBuildFile; fileRef = CF15F21C20E4F9A3008B1DE6 /* UIImageViewDeletable.m */; }; @@ -753,6 +755,16 @@ D3F7998115BD32370018C273 /* TPMultiLayoutViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = D3F7998015BD32370018C273 /* TPMultiLayoutViewController.m */; }; D3F83EEC1582021700336684 /* CallView.m in Sources */ = {isa = PBXBuildFile; fileRef = D3F83EEA1582021700336684 /* CallView.m */; }; D3F83F8E15822ABE00336684 /* PhoneMainView.m in Sources */ = {isa = PBXBuildFile; fileRef = D3F83F8D15822ABD00336684 /* PhoneMainView.m */; }; + EA0007A62356008F003CC6BF /* msgNotificationService.appex in Embed App Extensions */ = {isa = PBXBuildFile; fileRef = EA5F25D9232BD3E200475F2E /* msgNotificationService.appex */; settings = {ATTRIBUTES = (RemoveHeadersOnCopy, ); }; }; + EA3650DB2330D2E30001148A /* NotificationService.swift in Sources */ = {isa = PBXBuildFile; fileRef = EA5F25DB232BD3E200475F2E /* NotificationService.swift */; }; + EA88F3AB241BD05200E66528 /* UserNotifications.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8C73477B1D9BA3A00022EE8C /* UserNotifications.framework */; }; + EA88F3AC241BD05200E66528 /* UserNotificationsUI.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5E58962520DCE5700030868C /* UserNotificationsUI.framework */; }; + EA88F3AF241BD1F700E66528 /* MainInterface.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = EA8CB82D239F96CA00C330CC /* MainInterface.storyboard */; }; + EA88F3B1241BDAA100E66528 /* CoreManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = EA88F3B0241BDAA100E66528 /* CoreManager.swift */; }; + EA8CB82C239F96CA00C330CC /* NotificationViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = EA8CB82B239F96CA00C330CC /* NotificationViewController.swift */; }; + EA8CB833239F96CA00C330CC /* msgNotificationContent.appex in Embed App Extensions */ = {isa = PBXBuildFile; fileRef = EA8CB827239F96CA00C330CC /* msgNotificationContent.appex */; settings = {ATTRIBUTES = (RemoveHeadersOnCopy, ); }; }; + EAE6C88423FABF690076A018 /* Utils.swift in Sources */ = {isa = PBXBuildFile; fileRef = EAE6C88323FABF690076A018 /* Utils.swift */; }; + EAE6C88523FABF690076A018 /* Utils.swift in Sources */ = {isa = PBXBuildFile; fileRef = EAE6C88323FABF690076A018 /* Utils.swift */; }; F03CA84318C72F1A0008889D /* UITextViewNoDefine.m in Sources */ = {isa = PBXBuildFile; fileRef = F03CA84218C72F1A0008889D /* UITextViewNoDefine.m */; }; F05BAA621A5D594E00411815 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = F05BAA611A5D594E00411815 /* libz.dylib */; }; F0642EF119DAC891009DB336 /* MainStoryboard.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = F0642EF019DAC891009DB336 /* MainStoryboard.storyboard */; }; @@ -770,6 +782,20 @@ remoteGlobalIDString = 61AE364A20C00B370089D9D3; remoteInfo = linphoneExtension; }; + EA88F393241BC1F400E66528 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = EA5F25D8232BD3E200475F2E; + remoteInfo = msgNotificationService; + }; + EA88F394241BC1F400E66528 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = EA8CB826239F96CA00C330CC; + remoteInfo = msgNotificationContent; + }; /* End PBXContainerItemProxy section */ /* Begin PBXCopyFilesBuildPhase section */ @@ -780,6 +806,8 @@ dstSubfolderSpec = 13; files = ( 61AE365620C00B370089D9D3 /* linphoneExtension.appex in Embed App Extensions */, + EA8CB833239F96CA00C330CC /* msgNotificationContent.appex in Embed App Extensions */, + EA0007A62356008F003CC6BF /* msgNotificationService.appex in Embed App Extensions */, ); name = "Embed App Extensions"; runOnlyForDeploymentPostprocessing = 0; @@ -798,6 +826,7 @@ /* Begin PBXFileReference section */ 046DEFE77AD0675DA9932C4C /* Pods-liblinphoneTesterTests.distributionadhoc.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-liblinphoneTesterTests.distributionadhoc.xcconfig"; path = "Pods/Target Support Files/Pods-liblinphoneTesterTests/Pods-liblinphoneTesterTests.distributionadhoc.xcconfig"; sourceTree = ""; }; + 13B1BD646346F33BF57412F2 /* Pods-messagesNotification.distribution.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-messagesNotification.distribution.xcconfig"; path = "Pods/Target Support Files/Pods-messagesNotification/Pods-messagesNotification.distribution.xcconfig"; sourceTree = ""; }; 152F22351B15E889008C0621 /* libxml2.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libxml2.dylib; path = usr/lib/libxml2.dylib; sourceTree = SDKROOT; }; 1D30AB110D05D00D00671497 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 1D3623240D0F684500981E51 /* LinphoneAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LinphoneAppDelegate.h; sourceTree = ""; }; @@ -865,6 +894,7 @@ 288765FC0DF74451002DB57D /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 29B97316FDCFA39411CA2CEA /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 32CA4F630368D1EE00C91783 /* linphone_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = linphone_Prefix.pch; sourceTree = ""; }; + 34027665305514025971F85C /* Pods-msgNotificationContent.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-msgNotificationContent.release.xcconfig"; path = "Pods/Target Support Files/Pods-msgNotificationContent/Pods-msgNotificationContent.release.xcconfig"; sourceTree = ""; }; 340751961506459A00B89C47 /* CoreTelephony.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreTelephony.framework; path = System/Library/Frameworks/CoreTelephony.framework; sourceTree = SDKROOT; }; 340751E5150F38FC00B89C47 /* UIVideoButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIVideoButton.h; sourceTree = ""; }; 340751E6150F38FD00B89C47 /* UIVideoButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UIVideoButton.m; sourceTree = ""; }; @@ -1512,14 +1542,18 @@ 65CEDD144CABFAA70A29AF27 /* Pods_linphone.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_linphone.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 68D9EC27FCECD5DE2E19CD3C /* Pods-liblinphoneTester.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-liblinphoneTester.debug.xcconfig"; path = "Pods/Target Support Files/Pods-liblinphoneTester/Pods-liblinphoneTester.debug.xcconfig"; sourceTree = ""; }; 6E1BC45342F5201DABD7FE55 /* Pods_latestCallsWidget.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_latestCallsWidget.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 6F30EA7BEA39DA427CE0754E /* Pods_msgNotificationService.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_msgNotificationService.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 70E542F213E147E3002BA2C0 /* OpenGLES.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGLES.framework; path = System/Library/Frameworks/OpenGLES.framework; sourceTree = SDKROOT; }; 70E542F413E147EB002BA2C0 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 7513CBF7F2BA0A9F99977C2B /* Pods_richNotifications.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_richNotifications.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 78C7025E626D12D2F04EAC87 /* Pods-linphoneExtension.distribution.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-linphoneExtension.distribution.xcconfig"; path = "Pods/Target Support Files/Pods-linphoneExtension/Pods-linphoneExtension.distribution.xcconfig"; sourceTree = ""; }; + 791017662FE117B9B12E8938 /* Pods-messagesNotification.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-messagesNotification.debug.xcconfig"; path = "Pods/Target Support Files/Pods-messagesNotification/Pods-messagesNotification.debug.xcconfig"; sourceTree = ""; }; 799BA1104845EB01ACE764D8 /* Pods-linphone.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-linphone.debug.xcconfig"; path = "Pods/Target Support Files/Pods-linphone/Pods-linphone.debug.xcconfig"; sourceTree = ""; }; 7D8CCFE176C634813E3A2593 /* Pods-liblinphoneTesterTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-liblinphoneTesterTests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-liblinphoneTesterTests/Pods-liblinphoneTesterTests.debug.xcconfig"; sourceTree = ""; }; + 82E9DEDA2A78C6DBBD1A54DB /* Pods_msgNotificationContent.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_msgNotificationContent.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 85FB19B6A8124D942C8471F1 /* Pods-linphoneTests.distribution.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-linphoneTests.distribution.xcconfig"; path = "Pods/Target Support Files/Pods-linphoneTests/Pods-linphoneTests.distribution.xcconfig"; sourceTree = ""; }; 8B488C393394746F9D630789 /* Pods_latestChatroomsWidget.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_latestChatroomsWidget.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 8B4C43A28E90775F6FCA2CEE /* Pods-msgNotificationContent.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-msgNotificationContent.debug.xcconfig"; path = "Pods/Target Support Files/Pods-msgNotificationContent/Pods-msgNotificationContent.debug.xcconfig"; sourceTree = ""; }; 8C1A1F7C1FA331D40064BE00 /* libsoci_sqlite3.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libsoci_sqlite3.a; path = "liblinphone-sdk/apple-darwin/lib/libsoci_sqlite3.a"; sourceTree = ""; }; 8C1B67051E671826001EA2FE /* AudioHelper.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AudioHelper.m; sourceTree = ""; }; 8C1B67081E6718BC001EA2FE /* AudioHelper.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = AudioHelper.h; path = Utils/AudioHelper.h; sourceTree = ""; }; @@ -1619,13 +1653,18 @@ 8CF25D941F9F336100BEA0C1 /* check_unselected.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = check_unselected.png; sourceTree = ""; }; 8CF25D9B1F9F76BC00BEA0C1 /* chat_group_informations.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = chat_group_informations.png; sourceTree = ""; }; 8CF25D9C1F9F76BD00BEA0C1 /* chat_group_informations@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "chat_group_informations@2x.png"; sourceTree = ""; }; + 8FD0D10102F0A8922703B8A4 /* Pods-msgNotificationService.distributionadhoc.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-msgNotificationService.distributionadhoc.xcconfig"; path = "Pods/Target Support Files/Pods-msgNotificationService/Pods-msgNotificationService.distributionadhoc.xcconfig"; sourceTree = ""; }; + 904C1EC75CB9E03374AAA802 /* Pods-msgNotificationService.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-msgNotificationService.release.xcconfig"; path = "Pods/Target Support Files/Pods-msgNotificationService/Pods-msgNotificationService.release.xcconfig"; sourceTree = ""; }; 9CBD6E980619195CB7EE32AC /* Pods_liblinphoneTester.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_liblinphoneTester.framework; sourceTree = BUILT_PRODUCTS_DIR; }; ABB887316C42EE876A3051A9 /* Pods-linphoneTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-linphoneTests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-linphoneTests/Pods-linphoneTests.debug.xcconfig"; sourceTree = ""; }; + ADCA571A7CF61077747BFE53 /* Pods-msgNotificationService.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-msgNotificationService.debug.xcconfig"; path = "Pods/Target Support Files/Pods-msgNotificationService/Pods-msgNotificationService.debug.xcconfig"; sourceTree = ""; }; + BAD0A9494E833034EB559687 /* Pods-msgNotificationContent.distributionadhoc.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-msgNotificationContent.distributionadhoc.xcconfig"; path = "Pods/Target Support Files/Pods-msgNotificationContent/Pods-msgNotificationContent.distributionadhoc.xcconfig"; sourceTree = ""; }; BE06BDE664323B2A53469696 /* Pods-liblinphoneTesterTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-liblinphoneTesterTests.release.xcconfig"; path = "Pods/Target Support Files/Pods-liblinphoneTesterTests/Pods-liblinphoneTesterTests.release.xcconfig"; sourceTree = ""; }; BEBE8FB918176C388C01CFF7 /* Pods_linphoneExtension.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_linphoneExtension.framework; sourceTree = BUILT_PRODUCTS_DIR; }; C90FAA7615AF54E6002091CB /* HistoryDetailsView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HistoryDetailsView.h; sourceTree = ""; }; C90FAA7715AF54E6002091CB /* HistoryDetailsView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HistoryDetailsView.m; sourceTree = ""; }; C9B3A6FD15B485DB006F52EE /* Utils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Utils.h; path = Utils/Utils.h; sourceTree = ""; }; + CC6F924A8B1B1698914A3BB2 /* Pods-messagesNotification.distributionadhoc.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-messagesNotification.distributionadhoc.xcconfig"; path = "Pods/Target Support Files/Pods-messagesNotification/Pods-messagesNotification.distributionadhoc.xcconfig"; sourceTree = ""; }; CE119C214B6B8B2740622BBD /* Pods-linphoneTests.distributionadhoc.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-linphoneTests.distributionadhoc.xcconfig"; path = "Pods/Target Support Files/Pods-linphoneTests/Pods-linphoneTests.distributionadhoc.xcconfig"; sourceTree = ""; }; CF15F21B20E4F9A3008B1DE6 /* UIImageViewDeletable.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UIImageViewDeletable.h; sourceTree = ""; }; CF15F21C20E4F9A3008B1DE6 /* UIImageViewDeletable.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UIImageViewDeletable.m; sourceTree = ""; }; @@ -1758,7 +1797,20 @@ D3F83EEA1582021700336684 /* CallView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CallView.m; sourceTree = ""; }; D3F83F8C158229C500336684 /* PhoneMainView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PhoneMainView.h; sourceTree = ""; }; D3F83F8D15822ABD00336684 /* PhoneMainView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PhoneMainView.m; sourceTree = ""; }; + E40C9A7D22675584396C0A3D /* Pods-msgNotificationContent.distribution.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-msgNotificationContent.distribution.xcconfig"; path = "Pods/Target Support Files/Pods-msgNotificationContent/Pods-msgNotificationContent.distribution.xcconfig"; sourceTree = ""; }; E5074CFA3AAD5A8B72956DDE /* Pods-linphoneExtension.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-linphoneExtension.debug.xcconfig"; path = "Pods/Target Support Files/Pods-linphoneExtension/Pods-linphoneExtension.debug.xcconfig"; sourceTree = ""; }; + EA5F25D9232BD3E200475F2E /* msgNotificationService.appex */ = {isa = PBXFileReference; explicitFileType = "wrapper.app-extension"; includeInIndex = 0; path = msgNotificationService.appex; sourceTree = BUILT_PRODUCTS_DIR; }; + EA5F25DB232BD3E200475F2E /* NotificationService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NotificationService.swift; sourceTree = ""; }; + EA5F25DD232BD3E200475F2E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + EA88F3B0241BDAA100E66528 /* CoreManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CoreManager.swift; sourceTree = ""; }; + EA8CB827239F96CA00C330CC /* msgNotificationContent.appex */ = {isa = PBXFileReference; explicitFileType = "wrapper.app-extension"; includeInIndex = 0; path = msgNotificationContent.appex; sourceTree = BUILT_PRODUCTS_DIR; }; + EA8CB82B239F96CA00C330CC /* NotificationViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NotificationViewController.swift; sourceTree = ""; }; + EA8CB82E239F96CA00C330CC /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/MainInterface.storyboard; sourceTree = ""; }; + EA8CB830239F96CA00C330CC /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + EA8CB83F239FD41400C330CC /* msgNotificationContent.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = msgNotificationContent.entitlements; sourceTree = ""; }; + EAB783CF232F8E4D0076B1A0 /* msgNotificationService.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = msgNotificationService.entitlements; sourceTree = ""; }; + EAE6C88323FABF690076A018 /* Utils.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = Utils.swift; path = msgNotification/Utils.swift; sourceTree = SOURCE_ROOT; }; + EE807919DDB0B4B46AD1D439 /* Pods-messagesNotification.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-messagesNotification.release.xcconfig"; path = "Pods/Target Support Files/Pods-messagesNotification/Pods-messagesNotification.release.xcconfig"; sourceTree = ""; }; F0181B6B18BF7B1200A9A357 /* SenTestingKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SenTestingKit.framework; path = Library/Frameworks/SenTestingKit.framework; sourceTree = DEVELOPER_DIR; }; F03A9B9418C0DAE100C4D7FE /* libstdc++.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = "libstdc++.dylib"; path = "usr/lib/libstdc++.dylib"; sourceTree = SDKROOT; }; F03A9B9718C0DB6F00C4D7FE /* libc++.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = "libc++.dylib"; path = "usr/lib/libc++.dylib"; sourceTree = SDKROOT; }; @@ -1820,6 +1872,7 @@ F0BB8C4A193631B300974404 /* ImageIO.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ImageIO.framework; path = System/Library/Frameworks/ImageIO.framework; sourceTree = SDKROOT; }; F0FF66AA1ACAEEB0008A4486 /* IOKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = IOKit.framework; path = ../../../../Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/IOKit.framework; sourceTree = ""; }; F325590DD6CD7F6CC8F60C03 /* Pods_linphoneTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_linphoneTests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + F4BE1A2318FC69D799C34F0A /* Pods-msgNotificationService.distribution.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-msgNotificationService.distribution.xcconfig"; path = "Pods/Target Support Files/Pods-msgNotificationService/Pods-msgNotificationService.distribution.xcconfig"; sourceTree = ""; }; F6373F9231918DECD2B3004D /* Pods-linphoneTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-linphoneTests.release.xcconfig"; path = "Pods/Target Support Files/Pods-linphoneTests/Pods-linphoneTests.release.xcconfig"; sourceTree = ""; }; FD22CA9E3EFBFEFFF1B80BA2 /* Pods-liblinphoneTester.distributionadhoc.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-liblinphoneTester.distributionadhoc.xcconfig"; path = "Pods/Target Support Files/Pods-liblinphoneTester/Pods-liblinphoneTester.distributionadhoc.xcconfig"; sourceTree = ""; }; FE7D89A821FDC1BCA9BB9F8F /* Pods-linphone.distributionadhoc.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-linphone.distributionadhoc.xcconfig"; path = "Pods/Target Support Files/Pods-linphone/Pods-linphone.distributionadhoc.xcconfig"; sourceTree = ""; }; @@ -1827,6 +1880,16 @@ /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ + 143EFEE2501CB14E6BB244EF /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + EA88F3AC241BD05200E66528 /* UserNotificationsUI.framework in Frameworks */, + EA88F3AB241BD05200E66528 /* UserNotifications.framework in Frameworks */, + 369CCF81C921CD7C4E49A637 /* Pods_msgNotificationContent.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; 1D60588F0D05DD3D006BFB54 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; @@ -1869,6 +1932,14 @@ ); runOnlyForDeploymentPostprocessing = 0; }; + 203E6292C3E84CD13778F720 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 93566413F75DA69D2811A716 /* Pods_msgNotificationService.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; 61AE364820C00B370089D9D3 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; @@ -2016,6 +2087,7 @@ 34216F3F1547EBCD00EA9777 /* VideoZoomHandler.m */, 614C087723D1A35F00217F80 /* ProviderDelegate.swift */, 614C087923D1A37400217F80 /* CallManager.swift */, + EA88F3B0241BDAA100E66528 /* CoreManager.swift */, 6134812C2406CECC00695B41 /* ConfigManager.swift */, 6134812E2407B35200695B41 /* AppManager.swift */, 614C087623D1A35E00217F80 /* linphone-Bridging-Header.h */, @@ -2028,6 +2100,8 @@ children = ( 1D6058910D05DD3D006BFB54 /* linphone.app */, 61AE364B20C00B370089D9D3 /* linphoneExtension.appex */, + EA5F25D9232BD3E200475F2E /* msgNotificationService.appex */, + EA8CB827239F96CA00C330CC /* msgNotificationContent.appex */, ); name = Products; sourceTree = ""; @@ -2162,6 +2236,8 @@ 614D09CD21E74D5400C43EDF /* GoogleService-Info.plist */, 080E96DDFE201D6D7F000001 /* Classes */, 61AE364C20C00B370089D9D3 /* linphoneExtension */, + EA5F25DA232BD3E200475F2E /* msgNotificationService */, + EA8CB82A239F96CA00C330CC /* msgNotificationContent */, 29B97323FDCFA39411CA2CEA /* Frameworks */, F0938158188E629800A55DFA /* iTunesArtwork */, 29B97315FDCFA39411CA2CEA /* Other Sources */, @@ -2248,6 +2324,8 @@ BEBE8FB918176C388C01CFF7 /* Pods_linphoneExtension.framework */, F325590DD6CD7F6CC8F60C03 /* Pods_linphoneTests.framework */, 7513CBF7F2BA0A9F99977C2B /* Pods_richNotifications.framework */, + 82E9DEDA2A78C6DBBD1A54DB /* Pods_msgNotificationContent.framework */, + 6F30EA7BEA39DA427CE0754E /* Pods_msgNotificationService.framework */, ); name = Frameworks; sourceTree = ""; @@ -2275,6 +2353,18 @@ F6373F9231918DECD2B3004D /* Pods-linphoneTests.release.xcconfig */, 85FB19B6A8124D942C8471F1 /* Pods-linphoneTests.distribution.xcconfig */, CE119C214B6B8B2740622BBD /* Pods-linphoneTests.distributionadhoc.xcconfig */, + 791017662FE117B9B12E8938 /* Pods-messagesNotification.debug.xcconfig */, + EE807919DDB0B4B46AD1D439 /* Pods-messagesNotification.release.xcconfig */, + 13B1BD646346F33BF57412F2 /* Pods-messagesNotification.distribution.xcconfig */, + CC6F924A8B1B1698914A3BB2 /* Pods-messagesNotification.distributionadhoc.xcconfig */, + 8B4C43A28E90775F6FCA2CEE /* Pods-msgNotificationContent.debug.xcconfig */, + 34027665305514025971F85C /* Pods-msgNotificationContent.release.xcconfig */, + E40C9A7D22675584396C0A3D /* Pods-msgNotificationContent.distribution.xcconfig */, + BAD0A9494E833034EB559687 /* Pods-msgNotificationContent.distributionadhoc.xcconfig */, + ADCA571A7CF61077747BFE53 /* Pods-msgNotificationService.debug.xcconfig */, + 904C1EC75CB9E03374AAA802 /* Pods-msgNotificationService.release.xcconfig */, + F4BE1A2318FC69D799C34F0A /* Pods-msgNotificationService.distribution.xcconfig */, + 8FD0D10102F0A8922703B8A4 /* Pods-msgNotificationService.distributionadhoc.xcconfig */, ); name = Pods; sourceTree = ""; @@ -3017,6 +3107,28 @@ name = TPMultiLayoutViewController; sourceTree = ""; }; + EA5F25DA232BD3E200475F2E /* msgNotificationService */ = { + isa = PBXGroup; + children = ( + EAB783CF232F8E4D0076B1A0 /* msgNotificationService.entitlements */, + EAE6C88323FABF690076A018 /* Utils.swift */, + EA5F25DB232BD3E200475F2E /* NotificationService.swift */, + EA5F25DD232BD3E200475F2E /* Info.plist */, + ); + path = msgNotificationService; + sourceTree = ""; + }; + EA8CB82A239F96CA00C330CC /* msgNotificationContent */ = { + isa = PBXGroup; + children = ( + EA8CB83F239FD41400C330CC /* msgNotificationContent.entitlements */, + EA8CB82B239F96CA00C330CC /* NotificationViewController.swift */, + EA8CB82D239F96CA00C330CC /* MainInterface.storyboard */, + EA8CB830239F96CA00C330CC /* Info.plist */, + ); + path = msgNotificationContent; + sourceTree = ""; + }; /* End PBXGroup section */ /* Begin PBXNativeTarget section */ @@ -3037,6 +3149,8 @@ buildRules = ( ); dependencies = ( + EA8CB83A239F9A3000C330CC /* PBXTargetDependency */, + EA8CB83C239F9A3000C330CC /* PBXTargetDependency */, 61AE365520C00B370089D9D3 /* PBXTargetDependency */, ); name = linphone; @@ -3062,12 +3176,48 @@ productReference = 61AE364B20C00B370089D9D3 /* linphoneExtension.appex */; productType = "com.apple.product-type.app-extension"; }; + EA5F25D8232BD3E200475F2E /* msgNotificationService */ = { + isa = PBXNativeTarget; + buildConfigurationList = EA5F25E1232BD3E300475F2E /* Build configuration list for PBXNativeTarget "msgNotificationService" */; + buildPhases = ( + CD5CF0B3FE8B6052CD8219CE /* [CP] Check Pods Manifest.lock */, + EA5F25D5232BD3E200475F2E /* Sources */, + 203E6292C3E84CD13778F720 /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = msgNotificationService; + productName = messagesNotification; + productReference = EA5F25D9232BD3E200475F2E /* msgNotificationService.appex */; + productType = "com.apple.product-type.app-extension"; + }; + EA8CB826239F96CA00C330CC /* msgNotificationContent */ = { + isa = PBXNativeTarget; + buildConfigurationList = EA8CB834239F96CA00C330CC /* Build configuration list for PBXNativeTarget "msgNotificationContent" */; + buildPhases = ( + B0A561F0290F0342EACE9005 /* [CP] Check Pods Manifest.lock */, + EA8CB823239F96CA00C330CC /* Sources */, + 143EFEE2501CB14E6BB244EF /* Frameworks */, + EA88F3AE241BD1ED00E66528 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = msgNotificationContent; + productName = msgNotificationContent; + productReference = EA8CB827239F96CA00C330CC /* msgNotificationContent.appex */; + productType = "com.apple.product-type.app-extension"; + }; /* End PBXNativeTarget section */ /* Begin PBXProject section */ 29B97313FDCFA39411CA2CEA /* Project object */ = { isa = PBXProject; attributes = { + LastSwiftUpdateCheck = 1030; LastUpgradeCheck = 1130; TargetAttributes = { 1D6058900D05DD3D006BFB54 = { @@ -3102,6 +3252,26 @@ }; }; }; + EA5F25D8232BD3E200475F2E = { + CreatedOnToolsVersion = 11.0; + DevelopmentTeam = Z2V957B3D6; + ProvisioningStyle = Automatic; + SystemCapabilities = { + com.apple.ApplicationGroups.iOS = { + enabled = 1; + }; + }; + }; + EA8CB826239F96CA00C330CC = { + CreatedOnToolsVersion = 10.3; + DevelopmentTeam = Z2V957B3D6; + ProvisioningStyle = Automatic; + SystemCapabilities = { + com.apple.ApplicationGroups.iOS = { + enabled = 1; + }; + }; + }; }; }; buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "linphone" */; @@ -3134,6 +3304,8 @@ targets = ( 1D6058900D05DD3D006BFB54 /* linphone */, 61AE364A20C00B370089D9D3 /* linphoneExtension */, + EA5F25D8232BD3E200475F2E /* msgNotificationService */, + EA8CB826239F96CA00C330CC /* msgNotificationContent */, ); }; /* End PBXProject section */ @@ -3734,6 +3906,14 @@ ); runOnlyForDeploymentPostprocessing = 0; }; + EA88F3AE241BD1ED00E66528 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + EA88F3AF241BD1F700E66528 /* MainInterface.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; /* End PBXResourcesBuildPhase section */ /* Begin PBXShellScriptBuildPhase section */ @@ -3777,7 +3957,7 @@ "${PODS_ROOT}/linphone-sdk/linphone-sdk/apple-darwin/Frameworks/mswebrtc.framework", "${PODS_ROOT}/linphone-sdk/linphone-sdk/apple-darwin/Frameworks/msx264.framework", "${PODS_ROOT}/linphone-sdk/linphone-sdk/apple-darwin/Frameworks/ortp.framework", - "${BUILT_PRODUCTS_DIR}/linphone-sdk/linphonesw.framework", + "${BUILT_PRODUCTS_DIR}/linphone-sdk-ed2583cf/linphonesw.framework", "${PODS_ROOT}/linphone-sdk/linphone-sdk/apple-darwin/Frameworks/bctoolbox-ios.framework", ); name = "[CP] Embed Pods Frameworks"; @@ -3836,6 +4016,50 @@ shellPath = /bin/sh; shellScript = "$SRCROOT/Tools/git_version.sh\n"; }; + B0A561F0290F0342EACE9005 /* [CP] Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; + outputFileListPaths = ( + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-msgNotificationContent-checkManifestLockResult.txt", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + showEnvVarsInLog = 0; + }; + CD5CF0B3FE8B6052CD8219CE /* [CP] Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; + outputFileListPaths = ( + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-msgNotificationService-checkManifestLockResult.txt", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + showEnvVarsInLog = 0; + }; F43E063274A630F02AB2AAEC /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; @@ -3885,6 +4109,7 @@ 2214EBF312F86360002A5394 /* UIMutedMicroButton.m in Sources */, 8C9C5E111F83BD97006987FA /* UIChatCreateCollectionViewCell.m in Sources */, 22968A5F12F875C600588287 /* UISpeakerButton.m in Sources */, + EA88F3B1241BDAA100E66528 /* CoreManager.swift in Sources */, 63701DDF1BA32039006A9AE3 /* UIConfirmationDialog.m in Sources */, 6134812D2406CECC00695B41 /* ConfigManager.swift in Sources */, 22C755601317E59C007BC101 /* UIBluetoothButton.m in Sources */, @@ -4006,6 +4231,24 @@ ); runOnlyForDeploymentPostprocessing = 0; }; + EA5F25D5232BD3E200475F2E /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + EA3650DB2330D2E30001148A /* NotificationService.swift in Sources */, + EAE6C88423FABF690076A018 /* Utils.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + EA8CB823239F96CA00C330CC /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + EA8CB82C239F96CA00C330CC /* NotificationViewController.swift in Sources */, + EAE6C88523FABF690076A018 /* Utils.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; /* End PBXSourcesBuildPhase section */ /* Begin PBXTargetDependency section */ @@ -4014,6 +4257,16 @@ target = 61AE364A20C00B370089D9D3 /* linphoneExtension */; targetProxy = 61AE365420C00B370089D9D3 /* PBXContainerItemProxy */; }; + EA8CB83A239F9A3000C330CC /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = EA5F25D8232BD3E200475F2E /* msgNotificationService */; + targetProxy = EA88F393241BC1F400E66528 /* PBXContainerItemProxy */; + }; + EA8CB83C239F9A3000C330CC /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = EA8CB826239F96CA00C330CC /* msgNotificationContent */; + targetProxy = EA88F394241BC1F400E66528 /* PBXContainerItemProxy */; + }; /* End PBXTargetDependency section */ /* Begin PBXVariantGroup section */ @@ -4464,6 +4717,14 @@ name = AssistantViewScreens.xib; sourceTree = ""; }; + EA8CB82D239F96CA00C330CC /* MainInterface.storyboard */ = { + isa = PBXVariantGroup; + children = ( + EA8CB82E239F96CA00C330CC /* Base */, + ); + name = MainInterface.storyboard; + sourceTree = ""; + }; F088488D19FF8C41007FFCF3 /* UIContactCell.xib */ = { isa = PBXVariantGroup; children = ( @@ -4530,7 +4791,7 @@ "-DENABLE_QRCODE=TRUE", "-DENABLE_SMS_INVITE=TRUE", "$(inherited)", - "-DLINPHONE_SDK_VERSION=\\\"4.4.0-alpha.113+593ee35\\\"", + "-DLINPHONE_SDK_VERSION=\\\"4.4.0-alpha.115+39ecb2b\\\"", ); PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone; PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)app"; @@ -4554,6 +4815,7 @@ 228B19A61302902F00F154D3 /* DistributionAdhoc */ = { isa = XCBuildConfiguration; buildSettings = { + APPLICATION_EXTENSION_API_ONLY = NO; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CLANG_CXX_LIBRARY = "compiler-default"; CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; @@ -4574,6 +4836,8 @@ CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; CODE_SIGN_IDENTITY = "iPhone Distribution: jehan monnier"; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = YES; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_THUMB_SUPPORT = NO; @@ -4589,7 +4853,8 @@ LIBRARY_SEARCH_PATHS = ""; OTHER_CFLAGS = "-DBCTBX_LOG_DOMAIN=\\\"ios\\\""; OTHER_CPLUSPLUSFLAGS = "$(OTHER_CFLAGS)"; - PROVISIONING_PROFILE = "0636A6EA-90EB-4D92-B707-19FC32F9A7CF"; + PROVISIONING_PROFILE = ""; + "PROVISIONING_PROFILE[arch=*]" = ""; SDKROOT = iphoneos; STANDARD_C_PLUS_PLUS_LIBRARY_TYPE = dynamic; TARGETED_DEVICE_FAMILY = "1,2"; @@ -4647,7 +4912,7 @@ "-DENABLE_QRCODE=TRUE", "-DENABLE_SMS_INVITE=TRUE", "$(inherited)", - "-DLINPHONE_SDK_VERSION=\\\"4.4.0-alpha.113+593ee35\\\"", + "-DLINPHONE_SDK_VERSION=\\\"4.4.0-alpha.115+39ecb2b\\\"", ); PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone; PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)app"; @@ -4670,6 +4935,7 @@ 22F3D55513CC3C9100A0DA02 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { + APPLICATION_EXTENSION_API_ONLY = NO; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CLANG_CXX_LIBRARY = "compiler-default"; CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; @@ -4690,6 +4956,8 @@ CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; CODE_SIGN_IDENTITY = "iPhone Developer"; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = YES; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_THUMB_SUPPORT = NO; @@ -4764,7 +5032,7 @@ "-DENABLE_QRCODE=TRUE", "-DENABLE_SMS_INVITE=TRUE", "$(inherited)", - "-DLINPHONE_SDK_VERSION=\\\"4.4.0-alpha.113+593ee35\\\"", + "-DLINPHONE_SDK_VERSION=\\\"4.4.0-alpha.115+39ecb2b\\\"", ); PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone; PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)app"; @@ -4787,6 +5055,7 @@ 22F51EE7107FA53D00F98953 /* Distribution */ = { isa = XCBuildConfiguration; buildSettings = { + APPLICATION_EXTENSION_API_ONLY = NO; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CLANG_CXX_LIBRARY = "compiler-default"; CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; @@ -4807,6 +5076,8 @@ CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; CODE_SIGN_IDENTITY = "iPhone Distribution: jehan monnier"; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = YES; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_THUMB_SUPPORT = NO; @@ -4822,7 +5093,7 @@ LIBRARY_SEARCH_PATHS = ""; OTHER_CFLAGS = "-DBCTBX_LOG_DOMAIN=\\\"ios\\\""; OTHER_CPLUSPLUSFLAGS = "$(OTHER_CFLAGS)"; - PROVISIONING_PROFILE = "C7F794BC-6D48-41F2-B37D-E1B1B1A40901"; + PROVISIONING_PROFILE = ""; SDKROOT = iphoneos; STANDARD_C_PLUS_PLUS_LIBRARY_TYPE = dynamic; TARGETED_DEVICE_FAMILY = "1,2"; @@ -4880,7 +5151,7 @@ "-DENABLE_QRCODE=TRUE", "-DENABLE_SMS_INVITE=TRUE", "$(inherited)", - "-DLINPHONE_SDK_VERSION=\\\"4.4.0-alpha.113+593ee35\\\"", + "-DLINPHONE_SDK_VERSION=\\\"4.4.0-alpha.115+39ecb2b\\\"", ); PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone; PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)app"; @@ -5111,7 +5382,6 @@ ONLY_ACTIVE_ARCH = YES; OTHER_CFLAGS = "-DBCTBX_LOG_DOMAIN=\\\"ios\\\""; OTHER_CPLUSPLUSFLAGS = "$(OTHER_CFLAGS)"; - PROVISIONING_PROFILE = "2AC0DC11-4546-47B6-8B8A-453CCA80903C"; SDKROOT = iphoneos; STANDARD_C_PLUS_PLUS_LIBRARY_TYPE = dynamic; TARGETED_DEVICE_FAMILY = "1,2"; @@ -5119,6 +5389,396 @@ }; name = Debug; }; + EA5F25E2232BD3E300475F2E /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = ADCA571A7CF61077747BFE53 /* Pods-msgNotificationService.debug.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + APPLICATION_EXTENSION_API_ONLY = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_ENTITLEMENTS = msgNotificationService/msgNotificationService.entitlements; + CODE_SIGN_IDENTITY = "iPhone Developer"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + CODE_SIGN_STYLE = Automatic; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + INFOPLIST_FILE = "$(SRCROOT)/msgNotificationService/Info.plist"; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone.msgNotificationService; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SKIP_INSTALL = YES; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + EA5F25E3232BD3E300475F2E /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 904C1EC75CB9E03374AAA802 /* Pods-msgNotificationService.release.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + APPLICATION_EXTENSION_API_ONLY = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_ENTITLEMENTS = msgNotificationService/msgNotificationService.entitlements; + CODE_SIGN_IDENTITY = "iPhone Developer"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + CODE_SIGN_STYLE = Automatic; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = NO; + ENABLE_NS_ASSERTIONS = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + INFOPLIST_FILE = "$(SRCROOT)/msgNotificationService/Info.plist"; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone.msgNotificationService; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SKIP_INSTALL = YES; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + EA5F25E4232BD3E300475F2E /* Distribution */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = F4BE1A2318FC69D799C34F0A /* Pods-msgNotificationService.distribution.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + APPLICATION_EXTENSION_API_ONLY = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_ENTITLEMENTS = msgNotificationService/msgNotificationService.entitlements; + CODE_SIGN_IDENTITY = "iPhone Developer"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + CODE_SIGN_STYLE = Automatic; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = NO; + ENABLE_NS_ASSERTIONS = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + INFOPLIST_FILE = "$(SRCROOT)/msgNotificationService/Info.plist"; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone.msgNotificationService; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SKIP_INSTALL = YES; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Distribution; + }; + EA5F25E5232BD3E300475F2E /* DistributionAdhoc */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 8FD0D10102F0A8922703B8A4 /* Pods-msgNotificationService.distributionadhoc.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + APPLICATION_EXTENSION_API_ONLY = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_ENTITLEMENTS = msgNotificationService/msgNotificationService.entitlements; + CODE_SIGN_IDENTITY = "iPhone Developer"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + CODE_SIGN_STYLE = Automatic; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = NO; + ENABLE_NS_ASSERTIONS = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + INFOPLIST_FILE = "$(SRCROOT)/msgNotificationService/Info.plist"; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone.msgNotificationService; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SKIP_INSTALL = YES; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = DistributionAdhoc; + }; + EA8CB835239F96CA00C330CC /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 8B4C43A28E90775F6FCA2CEE /* Pods-msgNotificationContent.debug.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_ENTITLEMENTS = msgNotificationContent/msgNotificationContent.entitlements; + CODE_SIGN_IDENTITY = "Apple Development"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + CODE_SIGN_STYLE = Automatic; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + INFOPLIST_FILE = msgNotificationContent/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone.msgNotificationContent; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SKIP_INSTALL = YES; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + EA8CB836239F96CA00C330CC /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 34027665305514025971F85C /* Pods-msgNotificationContent.release.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_ENTITLEMENTS = msgNotificationContent/msgNotificationContent.entitlements; + CODE_SIGN_IDENTITY = "Apple Development"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + CODE_SIGN_STYLE = Automatic; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = NO; + ENABLE_NS_ASSERTIONS = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + INFOPLIST_FILE = msgNotificationContent/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone.msgNotificationContent; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SKIP_INSTALL = YES; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + EA8CB837239F96CA00C330CC /* Distribution */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = E40C9A7D22675584396C0A3D /* Pods-msgNotificationContent.distribution.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_ENTITLEMENTS = msgNotificationContent/msgNotificationContent.entitlements; + CODE_SIGN_IDENTITY = "Apple Development"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + CODE_SIGN_STYLE = Automatic; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = NO; + ENABLE_NS_ASSERTIONS = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + INFOPLIST_FILE = msgNotificationContent/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone.msgNotificationContent; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SKIP_INSTALL = YES; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Distribution; + }; + EA8CB838239F96CA00C330CC /* DistributionAdhoc */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = BAD0A9494E833034EB559687 /* Pods-msgNotificationContent.distributionadhoc.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_ENTITLEMENTS = msgNotificationContent/msgNotificationContent.entitlements; + CODE_SIGN_IDENTITY = "Apple Development"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + CODE_SIGN_STYLE = Automatic; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = Z2V957B3D6; + ENABLE_BITCODE = NO; + ENABLE_NS_ASSERTIONS = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + INFOPLIST_FILE = msgNotificationContent/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + PRODUCT_BUNDLE_IDENTIFIER = org.linphone.phone.msgNotificationContent; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SKIP_INSTALL = YES; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = DistributionAdhoc; + }; /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ @@ -5155,6 +5815,28 @@ defaultConfigurationIsVisible = 0; defaultConfigurationName = Debug; }; + EA5F25E1232BD3E300475F2E /* Build configuration list for PBXNativeTarget "msgNotificationService" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + EA5F25E2232BD3E300475F2E /* Debug */, + EA5F25E3232BD3E300475F2E /* Release */, + EA5F25E4232BD3E300475F2E /* Distribution */, + EA5F25E5232BD3E300475F2E /* DistributionAdhoc */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; + EA8CB834239F96CA00C330CC /* Build configuration list for PBXNativeTarget "msgNotificationContent" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + EA8CB835239F96CA00C330CC /* Debug */, + EA8CB836239F96CA00C330CC /* Release */, + EA8CB837239F96CA00C330CC /* Distribution */, + EA8CB838239F96CA00C330CC /* DistributionAdhoc */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; /* End XCConfigurationList section */ }; rootObject = 29B97313FDCFA39411CA2CEA /* Project object */; diff --git a/msgNotification/Utils.swift b/msgNotification/Utils.swift new file mode 100644 index 000000000..b71cf93af --- /dev/null +++ b/msgNotification/Utils.swift @@ -0,0 +1,68 @@ +/* +* Copyright (c) 2010-2019 Belledonne Communications SARL. +* +* This file is part of linphone-iphone +* +* This program is free software: you can redistribute it and/or modify +* it under the terms of the GNU General Public License as published by +* the Free Software Foundation, either version 3 of the License, or +* (at your option) any later version. +* +* This program is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU General Public License for more details. +* +* You should have received a copy of the GNU General Public License +* along with this program. If not, see . +*/ + +import linphonesw + +enum LinphoneError: Error { + case timeout + case loggingServiceUninitialized +} + +class LinphoneLoggingServiceManager: LoggingServiceDelegate { + init(config: Config, log: LoggingService?, domain: String) throws { + if let log = log { + super.init() + let debugLevel = config.getInt(section: "app", key: "debugenable_preference", defaultValue: LogLevel.Debug.rawValue) + let debugEnabled = (debugLevel >= LogLevel.Debug.rawValue && debugLevel < LogLevel.Error.rawValue) + + if (debugEnabled) { + Factory.Instance.logCollectionPath = Factory.Instance.getDownloadPath(context: UnsafeMutablePointer(mutating: (GROUP_ID as NSString).utf8String)) + Factory.Instance.enableLogCollection(state: LogCollectionState.Enabled) + log.domain = domain + log.logLevel = LogLevel(rawValue: debugLevel) + log.addDelegate(delegate: self) + } + } else { + throw LinphoneError.loggingServiceUninitialized + } + } + + override func onLogMessageWritten(logService: LoggingService, domain: String, lev: LogLevel, message: String) { + let level: String + + switch lev { + case .Debug: + level = "Debug" + case .Trace: + level = "Trace" + case .Message: + level = "Message" + case .Warning: + level = "Warning" + case .Error: + level = "Error" + case .Fatal: + level = "Fatal" + default: + level = "unknown" + } + + NSLog("\(level) [\(domain)] \(message)\n") + } +} diff --git a/msgNotificationContent/Base.lproj/MainInterface.storyboard b/msgNotificationContent/Base.lproj/MainInterface.storyboard new file mode 100644 index 000000000..5d49f3ef0 --- /dev/null +++ b/msgNotificationContent/Base.lproj/MainInterface.storyboard @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/msgNotificationContent/Info.plist b/msgNotificationContent/Info.plist new file mode 100644 index 000000000..b7354f834 --- /dev/null +++ b/msgNotificationContent/Info.plist @@ -0,0 +1,40 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleDisplayName + msgNotificationContent + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + XPC! + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + NSExtension + + NSExtensionAttributes + + UNNotificationExtensionOverridesDefaultTitle + + UNNotificationExtensionCategory + msg_cat + UNNotificationExtensionInitialContentSizeRatio + 0.01 + + NSExtensionMainStoryboard + MainInterface + NSExtensionPointIdentifier + com.apple.usernotifications.content-extension + + + diff --git a/msgNotificationContent/NotificationViewController.swift b/msgNotificationContent/NotificationViewController.swift new file mode 100644 index 000000000..69f240424 --- /dev/null +++ b/msgNotificationContent/NotificationViewController.swift @@ -0,0 +1,181 @@ +/* +* Copyright (c) 2010-2019 Belledonne Communications SARL. +* +* This file is part of linphone-iphone +* +* This program is free software: you can redistribute it and/or modify +* it under the terms of the GNU General Public License as published by +* the Free Software Foundation, either version 3 of the License, or +* (at your option) any later version. +* +* This program is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU General Public License for more details. +* +* You should have received a copy of the GNU General Public License +* along with this program. If not, see . +*/ + +import UIKit +import UserNotifications +import UserNotificationsUI +import linphonesw + + +var GROUP_ID = "group.org.linphone.phone.msgNotification" +var isReplySent: Bool = false +var needToStop: Bool = false +var coreStopped: Bool = false +var log: LoggingService! + +class NotificationViewController: UIViewController, UNNotificationContentExtension { + + var lc: Core? + var config: Config! + var logDelegate: LinphoneLoggingServiceManager! + var msgDelegate: LinphoneChatMessageManager! + var coreDelegate: LinphoneCoreManager! + + override func viewDidLoad() { + super.viewDidLoad() + // Do any required interface initialization here. + NSLog("[msgNotificationContent] start msgNotificationContent extension") + + let replyAction = UNTextInputNotificationAction(identifier: "Reply", + title: NSLocalizedString("Reply", comment: ""), + options: [], + textInputButtonTitle: NSLocalizedString("Send", comment: ""), + textInputPlaceholder: "") + + let seenAction = UNNotificationAction(identifier: "Seen", title: NSLocalizedString("Mark as seen", comment: ""), options: []) + let category = UNNotificationCategory(identifier: "msg_cat", actions: [replyAction, seenAction], intentIdentifiers: [], options: [.customDismissAction]) + UNUserNotificationCenter.current().setNotificationCategories([category]) + + needToStop = false + isReplySent = false + coreStopped = false + } + + func didReceive(_ notification: UNNotification) { + self.title = "test test test" // TODO PAUL : a enlever + } + + func didReceive(_ response: UNNotificationResponse, + completionHandler completion: @escaping (UNNotificationContentExtensionResponseOption) -> Void) { + do { + let userInfo = response.notification.request.content.userInfo + switch response.actionIdentifier { + case "Reply": + if let replyText = response as? UNTextInputNotificationResponse { + try replyAction(userInfo, text: replyText.userText) + } + break + case "Seen": + try markAsSeenAction(userInfo) + break + default: + break + } + + if (needToStop) { + log.error(msg: "core stopped by app") + throw LinphoneError.timeout + } else { + completion(.dismiss) + stopCore() + } + + } catch { + log.error(msg: "error: \(error)") + completion(.dismissAndForwardAction) + } + } + + func markAsSeenAction(_ userInfo: [AnyHashable : Any]) throws { + NSLog("[msgNotificationContent] markAsSeenAction") + try startCore() + + let peerAddress = userInfo["peer_addr"] as! String + let localAddress = userInfo["local_addr"] as! String + let peer = try lc!.createAddress(address: peerAddress) + let local = try lc!.createAddress(address: localAddress) + let room = lc!.findChatRoom(peerAddr: peer, localAddr: local) + if let room = room { + room.markAsRead() + } + lc!.iterate() + } + + func replyAction(_ userInfo: [AnyHashable : Any], text replyText: String) throws { + NSLog("[msgNotificationContent] replyAction") + try startCore() + + let peerAddress = userInfo["peer_addr"] as! String + let localAddress = userInfo["local_addr"] as! String + let peer = try lc!.createAddress(address: peerAddress) + let local = try lc!.createAddress(address: localAddress) + let room = lc!.findChatRoom(peerAddr: peer, localAddr: local) + if let room = room { + msgDelegate = LinphoneChatMessageManager() + let chatMsg = try room.createMessage(message: replyText) + chatMsg.addDelegate(delegate: msgDelegate) + room.sendChatMessage(msg: chatMsg) + room.markAsRead() + } + + for i in 0...50 where !isReplySent && !needToStop { + log.debug(msg: "reply \(i)") + lc!.iterate() + usleep(10000) + } + } + + func startCore() throws { + config = Config.newForSharedCore(groupId: GROUP_ID, configFilename: "linphonerc", factoryPath: "") + log = LoggingService.Instance /*enable liblinphone logs.*/ + logDelegate = try! LinphoneLoggingServiceManager(config: config, log: log, domain: "msgNotificationContent") + lc = try! Factory.Instance.createSharedCoreWithConfig(config: config, systemContext: nil, appGroup: GROUP_ID, mainCore: false) + + coreDelegate = LinphoneCoreManager() + lc!.addDelegate(delegate: coreDelegate) + + try lc!.start() + log.message(msg: "core started") + + if (needToStop) { + log.error(msg: "core stopped by app") + throw LinphoneError.timeout + } + } + + func stopCore() { + lc!.stopAsync() + log.message(msg: "stop core") + for i in 0...100 where !coreStopped { + log.debug(msg: "stop \(i)") + lc!.iterate() + usleep(50000) + } + } + + class LinphoneCoreManager: CoreDelegate { + override func onGlobalStateChanged(lc: Core, gstate: GlobalState, message: String) { + log.message(msg: "global state changed: \(gstate) : \(message) \n") + if (gstate == .Shutdown) { + needToStop = true + } else if (gstate == .Off) { + coreStopped = true + } + } + } + + class LinphoneChatMessageManager: ChatMessageDelegate { + override func onMsgStateChanged(msg: ChatMessage, state: ChatMessage.State) { + log.message(msg: "msg state changed: \(state)\n") + if (state == .Delivered) { + isReplySent = true + } + } + } +} diff --git a/msgNotificationContent/msgNotificationContent.entitlements b/msgNotificationContent/msgNotificationContent.entitlements new file mode 100644 index 000000000..f176b9127 --- /dev/null +++ b/msgNotificationContent/msgNotificationContent.entitlements @@ -0,0 +1,10 @@ + + + + + com.apple.security.application-groups + + group.org.linphone.phone.msgNotification + + + diff --git a/msgNotificationService/Info.plist b/msgNotificationService/Info.plist new file mode 100644 index 000000000..15e6f8103 --- /dev/null +++ b/msgNotificationService/Info.plist @@ -0,0 +1,31 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleDisplayName + msgNotificationService + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + $(PRODUCT_BUNDLE_PACKAGE_TYPE) + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + NSExtension + + NSExtensionPointIdentifier + com.apple.usernotifications.service + NSExtensionPrincipalClass + $(PRODUCT_MODULE_NAME).NotificationService + + + diff --git a/msgNotificationService/NotificationService.swift b/msgNotificationService/NotificationService.swift new file mode 100644 index 000000000..25be51be1 --- /dev/null +++ b/msgNotificationService/NotificationService.swift @@ -0,0 +1,181 @@ +/* +* Copyright (c) 2010-2019 Belledonne Communications SARL. +* +* This file is part of linphone-iphone +* +* This program is free software: you can redistribute it and/or modify +* it under the terms of the GNU General Public License as published by +* the Free Software Foundation, either version 3 of the License, or +* (at your option) any later version. +* +* This program is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU General Public License for more details. +* +* You should have received a copy of the GNU General Public License +* along with this program. If not, see . +*/ + +import UserNotifications +import linphonesw + +var GROUP_ID = "group.org.linphone.phone.msgNotification" +var LINPHONE_DUMMY_SUBJECT = "dummy subject" + +struct MsgData: Codable { + var from: String? + var body: String? + var subtitle: String? + var callId: String? + var localAddr: String? + var peerAddr: String? +} + +class NotificationService: UNNotificationServiceExtension { + + var contentHandler: ((UNNotificationContent) -> Void)? + var bestAttemptContent: UNMutableNotificationContent? + + var lc: Core? + static var logDelegate: LinphoneLoggingServiceManager! + static var log: LoggingService! + + override func didReceive(_ request: UNNotificationRequest, withContentHandler contentHandler: @escaping (UNNotificationContent) -> Void) { + self.contentHandler = contentHandler + bestAttemptContent = (request.content.mutableCopy() as? UNMutableNotificationContent) + NSLog("[msgNotificationService] start msgNotificationService extension") + + if let bestAttemptContent = bestAttemptContent { + createCore() + + if let chatRoomInviteAddr = bestAttemptContent.userInfo["chat-room-addr"] as? String, !chatRoomInviteAddr.isEmpty { + NotificationService.log.message(msg: "fetch chat room for invite, addr: \(chatRoomInviteAddr)") + let chatRoom = lc!.getPushNotificationChatRoomInvite(chatRoomAddr: chatRoomInviteAddr) + + if let chatRoom = chatRoom { + stopCore() + NotificationService.log.message(msg: "chat room invite received") + bestAttemptContent.title = "You have been added to a chat room" + if (chatRoom.subject == LINPHONE_DUMMY_SUBJECT) { + bestAttemptContent.body = chatRoom.participants[0].address?.username as! String + } else { + bestAttemptContent.body = chatRoom.subject + } + + contentHandler(bestAttemptContent) + return + } + } else if let callId = bestAttemptContent.userInfo["call-id"] as? String { + NotificationService.log.message(msg: "fetch msg") + let message = lc!.getPushNotificationMessage(callId: callId) + + if let message = message, let chatRoom = message.chatRoom { + let msgData = parseMessage(room: chatRoom, message: message) + + if let badge = updateBadge() as NSNumber? { + bestAttemptContent.badge = badge + } + + stopCore() + + bestAttemptContent.sound = UNNotificationSound(named: UNNotificationSoundName(rawValue: "msg.caf")) + bestAttemptContent.title = NSLocalizedString("Message received", comment: "") + " [extension]" + if let subtitle = msgData?.subtitle { + bestAttemptContent.subtitle = subtitle + } + if let body = msgData?.body { + bestAttemptContent.body = body + } + + bestAttemptContent.categoryIdentifier = "msg_cat" + + bestAttemptContent.userInfo.updateValue(msgData?.callId as Any, forKey: "CallId") + bestAttemptContent.userInfo.updateValue(msgData?.from as Any, forKey: "from") + bestAttemptContent.userInfo.updateValue(msgData?.peerAddr as Any, forKey: "peer_addr") + bestAttemptContent.userInfo.updateValue(msgData?.localAddr as Any, forKey: "local_addr") + + contentHandler(bestAttemptContent) + return + } + } + serviceExtensionTimeWillExpire() + } + } + + override func serviceExtensionTimeWillExpire() { + // Called just before the extension will be terminated by the system. + // Use this as an opportunity to deliver your "best attempt" at modified content, otherwise the original push payload will be used. + stopCore() + if let contentHandler = contentHandler, let bestAttemptContent = bestAttemptContent { + NSLog("[msgNotificationService] serviceExtensionTimeWillExpire") + bestAttemptContent.categoryIdentifier = "app_active" + bestAttemptContent.title = NSLocalizedString("Message received", comment: "") + " [time out]" // TODO PAUL : a enlever + bestAttemptContent.body = NSLocalizedString("You have received a message.", comment: "") + contentHandler(bestAttemptContent) + } + } + + func parseMessage(room: ChatRoom, message: ChatMessage) -> MsgData? { + NotificationService.log.message(msg: "Core received msg \(message.contentType) \n") + + if (message.contentType != "text/plain" && message.contentType != "image/jpeg") { + return nil + } + + let content = message.isText ? message.textContent : "🗻" + let from = message.fromAddress?.username + let callId = message.getCustomHeader(headerName: "Call-Id") + let localUri = room.localAddress?.asStringUriOnly() + let peerUri = room.peerAddress?.asStringUriOnly() + + var msgData = MsgData(from: from, body: "", subtitle: "", callId:callId, localAddr: localUri, peerAddr:peerUri) + + if let showMsg = lc!.config?.getBool(section: "app", key: "show_msg_in_notif", defaultValue: true), showMsg == true { + if let subject = room.subject as String?, subject != "" { + msgData.subtitle = subject + msgData.body = from! + " : " + content + } else { + msgData.subtitle = from + msgData.body = content + } + } else { + if let subject = room.subject as String?, subject != "" { + msgData.body = subject + " : " + from! + } else { + msgData.body = from + } + } + + NotificationService.log.message(msg: "msg: \(content) \n") + return msgData; + } + + func createCore() { + NSLog("[msgNotificationService] create core") + let config = Config.newForSharedCore(groupId: GROUP_ID, configFilename: "linphonerc", factoryPath: "") + + if (NotificationService.log == nil || NotificationService.log.getDelegate() == nil) { + NotificationService.log = LoggingService.Instance /*enable liblinphone logs.*/ + NotificationService.logDelegate = try! LinphoneLoggingServiceManager(config: config!, log: NotificationService.log, domain: "msgNotificationService") + } + lc = try! Factory.Instance.createSharedCoreWithConfig(config: config!, systemContext: nil, appGroup: GROUP_ID, mainCore: false) + } + + func stopCore() { + NotificationService.log.message(msg: "stop core") + if let lc = lc { + lc.stop() + } + } + + func updateBadge() -> Int { + var count = 0 + count += lc!.unreadChatMessageCount + count += lc!.missedCallsCount + count += lc!.callsNb + NotificationService.log.message(msg: "badge: \(count)\n") + + return count + } +} diff --git a/msgNotificationService/msgNotificationService.entitlements b/msgNotificationService/msgNotificationService.entitlements new file mode 100644 index 000000000..f176b9127 --- /dev/null +++ b/msgNotificationService/msgNotificationService.entitlements @@ -0,0 +1,10 @@ + + + + + com.apple.security.application-groups + + group.org.linphone.phone.msgNotification + + +