From 56ad53e761115de5e9ef05e1fa600dfd041e8756 Mon Sep 17 00:00:00 2001 From: overtake <> Date: Wed, 21 Nov 2018 01:10:25 +0400 Subject: [PATCH] notification exceptions --- TelegramUI/ChatListSearchContainerNode.swift | 3 ++- TelegramUI/NotificationExceptionControllerNode.swift | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/TelegramUI/ChatListSearchContainerNode.swift b/TelegramUI/ChatListSearchContainerNode.swift index 54f8143968..c0547c7e2e 100644 --- a/TelegramUI/ChatListSearchContainerNode.swift +++ b/TelegramUI/ChatListSearchContainerNode.swift @@ -556,7 +556,8 @@ final class ChatListSearchContainerNode: SearchDisplayControllerContentNode { self.dimNode.backgroundColor = filter.contains(.excludeRecent) ? UIColor.black.withAlphaComponent(0.5) : self.presentationData.theme.chatList.backgroundColor - //self.backgroundColor = + self.backgroundColor = filter.contains(.excludeRecent) ? nil : self.presentationData.theme.chatList.backgroundColor + self.addSubnode(self.dimNode) self.addSubnode(self.recentListNode) diff --git a/TelegramUI/NotificationExceptionControllerNode.swift b/TelegramUI/NotificationExceptionControllerNode.swift index 6c52c82922..3c6ef327a6 100644 --- a/TelegramUI/NotificationExceptionControllerNode.swift +++ b/TelegramUI/NotificationExceptionControllerNode.swift @@ -645,7 +645,7 @@ final class NotificationExceptionsControllerNode: ViewControllerTracingNode { presentControllerImpl?(notificationPeerExceptionController(account: account, peerId: peerId, mode: mode, updatePeerSound: { peerId, sound in _ = updatePeerSound(peerId, sound).start(next: { _ in - _ = (account.postbox.loadedPeerWithId(peerId) |> deliverOnMainQueue).start(next: { peer in + _ = combineLatest(updatePeerSound(peerId, sound), account.postbox.loadedPeerWithId(peerId) |> deliverOnMainQueue).start(next: { _, peer in updateState { value in return value.withUpdatedPeerSound(peer, sound) } @@ -654,7 +654,7 @@ final class NotificationExceptionsControllerNode: ViewControllerTracingNode { }) }, updatePeerNotificationInterval: { peerId, muteInterval in - _ = (account.postbox.loadedPeerWithId(peerId) |> deliverOnMainQueue).start(next: { peer in + _ = combineLatest(updatePeerNotificationInterval(peerId, muteInterval), account.postbox.loadedPeerWithId(peerId) |> deliverOnMainQueue).start(next: { _, peer in updateState { value in return value.withUpdatedPeerMuteInterval(peer, muteInterval) }