mirror of
https://github.com/oxen-io/session-ios.git
synced 2023-12-13 21:30:14 +01:00
Merge branch 'mkirk/notification-race' into release/2.39.0
This commit is contained in:
commit
c59613557e
|
@ -496,10 +496,12 @@ public class NotificationPresenter: NSObject, NotificationsProtocol {
|
|||
}
|
||||
}
|
||||
|
||||
@objc
|
||||
public func cancelNotifications(threadId: String) {
|
||||
self.adaptee.cancelNotifications(threadId: threadId)
|
||||
}
|
||||
|
||||
@objc
|
||||
public func clearAllNotifications() {
|
||||
adaptee.clearAllNotifications()
|
||||
}
|
||||
|
|
|
@ -325,6 +325,11 @@ typedef enum : NSUInteger {
|
|||
return SSKEnvironment.shared.tsAccountManager;
|
||||
}
|
||||
|
||||
- (OWSNotificationPresenter *)notificationPresenter
|
||||
{
|
||||
return AppEnvironment.shared.notificationPresenter;
|
||||
}
|
||||
|
||||
#pragma mark -
|
||||
|
||||
- (void)addNotificationListeners
|
||||
|
@ -1187,6 +1192,13 @@ typedef enum : NSUInteger {
|
|||
{
|
||||
[super viewDidAppear:animated];
|
||||
|
||||
// We don't present incoming message notifications for the presented
|
||||
// conversation. But there's a narrow window *while* the conversationVC
|
||||
// is being presented where a message notification for the not-quite-yet
|
||||
// presented conversation can be shown. If that happens, dismiss it as soon
|
||||
// as we enter the conversation.
|
||||
[self.notificationPresenter cancelNotificationsWithThreadId:self.thread.uniqueId];
|
||||
|
||||
// recover status bar when returning from PhotoPicker, which is dark (uses light status bar)
|
||||
[self setNeedsStatusBarAppearanceUpdate];
|
||||
|
||||
|
|
Loading…
Reference in a new issue