From 96b9a99be78b87f1232a4600790f29206c596924 Mon Sep 17 00:00:00 2001 From: Ali <> Date: Thu, 27 May 2021 13:22:59 +0400 Subject: [PATCH 1/2] Fix bubble background --- .../Sources/WallpaperBackgroundNode.swift | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/submodules/WallpaperBackgroundNode/Sources/WallpaperBackgroundNode.swift b/submodules/WallpaperBackgroundNode/Sources/WallpaperBackgroundNode.swift index c531b0c0ea..f543532c14 100644 --- a/submodules/WallpaperBackgroundNode/Sources/WallpaperBackgroundNode.swift +++ b/submodules/WallpaperBackgroundNode/Sources/WallpaperBackgroundNode.swift @@ -56,13 +56,22 @@ public final class WallpaperBackgroundNode: ASDisplayNode { if let bubbleTheme = backgroundNode.bubbleTheme, let wallpaper = backgroundNode.wallpaper, let bubbleCorners = backgroundNode.bubbleCorners { let graphics = PresentationResourcesChat.principalGraphics(theme: bubbleTheme, wallpaper: wallpaper, bubbleCorners: bubbleCorners) var needsCleanBackground = false - self.contentNode.backgroundColor = backgroundNode.contentNode.backgroundColor switch self.bubbleType { case .incoming: self.contentNode.image = graphics.incomingBubbleGradientImage + if graphics.incomingBubbleGradientImage == nil { + self.contentNode.backgroundColor = bubbleTheme.chat.message.incoming.bubble.withWallpaper.fill + } else { + self.contentNode.backgroundColor = nil + } needsCleanBackground = bubbleTheme.chat.message.incoming.bubble.withWallpaper.fill.alpha <= 0.99 || bubbleTheme.chat.message.incoming.bubble.withWallpaper.gradientFill.alpha <= 0.99 case .outgoing: self.contentNode.image = graphics.outgoingBubbleGradientImage + if graphics.outgoingBubbleGradientImage == nil { + self.contentNode.backgroundColor = bubbleTheme.chat.message.outgoing.bubble.withWallpaper.fill + } else { + self.contentNode.backgroundColor = nil + } needsCleanBackground = bubbleTheme.chat.message.outgoing.bubble.withWallpaper.fill.alpha <= 0.99 || bubbleTheme.chat.message.outgoing.bubble.withWallpaper.gradientFill.alpha <= 0.99 } @@ -98,6 +107,7 @@ public final class WallpaperBackgroundNode: ASDisplayNode { self.insertSubnode(cleanWallpaperNode, at: 0) } self.cleanWallpaperNode?.contents = backgroundNode.contentNode.contents + self.cleanWallpaperNode?.backgroundColor = backgroundNode.contentNode.backgroundColor } else { if let cleanWallpaperNode = self.cleanWallpaperNode { self.cleanWallpaperNode = nil From 0559c2652c6bc10b5b20b8db6cf5ca206a38d805 Mon Sep 17 00:00:00 2001 From: Ali <> Date: Thu, 27 May 2021 13:25:04 +0400 Subject: [PATCH 2/2] Update tgcalls --- submodules/TgVoipWebrtc/tgcalls | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/TgVoipWebrtc/tgcalls b/submodules/TgVoipWebrtc/tgcalls index e75e19b1de..aad8bff9bf 160000 --- a/submodules/TgVoipWebrtc/tgcalls +++ b/submodules/TgVoipWebrtc/tgcalls @@ -1 +1 @@ -Subproject commit e75e19b1ded7a8512d50b6e0be83408376ca0838 +Subproject commit aad8bff9bf56b83e46c92bb1157c764544e91001