mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 11:08:06 +00:00
repair flexisip pusher notification display
This commit is contained in:
parent
d0a7f4ede1
commit
392f991fae
2 changed files with 13 additions and 1 deletions
|
|
@ -436,7 +436,7 @@
|
|||
return;
|
||||
}
|
||||
|
||||
NSString *loc_key = [aps objectForKey:@"loc-key"];
|
||||
NSString *loc_key = [aps objectForKey:@"loc-key"] ?: [[aps objectForKey:@"alert"] objectForKey:@"loc-key"];
|
||||
NSString *callId = [aps objectForKey:@"call-id"] ?: @"";
|
||||
if (!loc_key) {
|
||||
LOGE(@"Notification [%p] has no loc_key, it's impossible to process it.", userInfo);
|
||||
|
|
@ -486,6 +486,12 @@
|
|||
}
|
||||
|
||||
- (BOOL)addLongTaskIDforCallID:(NSString *)callId {
|
||||
if (!callId)
|
||||
return FALSE;
|
||||
|
||||
if ([callId isEqualToString:@""])
|
||||
return FALSE;
|
||||
|
||||
NSDictionary *dict = LinphoneManager.instance.pushDict;
|
||||
if ([[dict allKeys] indexOfObject:callId] != NSNotFound)
|
||||
return FALSE;
|
||||
|
|
|
|||
|
|
@ -2161,6 +2161,12 @@ static int comp_call_state_paused(const LinphoneCall *call, const void *param) {
|
|||
}
|
||||
|
||||
- (void)startPushLongRunningTask:(NSString *)loc_key callId:(NSString *)callId {
|
||||
if (!callId)
|
||||
return;
|
||||
|
||||
if ([callId isEqualToString:@""])
|
||||
return;
|
||||
|
||||
if ([loc_key isEqualToString:@"IM_MSG"]) {
|
||||
[[UIApplication sharedApplication] endBackgroundTask:pushBgTaskMsg];
|
||||
pushBgTaskMsg = 0;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue