mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
Various fixes
This commit is contained in:
parent
77d45e60bc
commit
ba24da0593
@ -1227,15 +1227,18 @@ public final class AvatarNode: ASDisplayNode {
|
||||
public var colors: Colors
|
||||
public var lineWidth: CGFloat
|
||||
public var inactiveLineWidth: CGFloat
|
||||
public var forceRoundedRect: Bool
|
||||
|
||||
public init(
|
||||
colors: Colors,
|
||||
lineWidth: CGFloat,
|
||||
inactiveLineWidth: CGFloat
|
||||
inactiveLineWidth: CGFloat,
|
||||
forceRoundedRect: Bool = false
|
||||
) {
|
||||
self.colors = colors
|
||||
self.lineWidth = lineWidth
|
||||
self.inactiveLineWidth = inactiveLineWidth
|
||||
self.forceRoundedRect = forceRoundedRect
|
||||
}
|
||||
}
|
||||
|
||||
@ -1290,7 +1293,7 @@ public final class AvatarNode: ASDisplayNode {
|
||||
unseenCount: storyStats.unseenCount
|
||||
),
|
||||
progress: mappedProgress,
|
||||
isRoundedRect: self.contentNode.clipStyle == .roundedRect
|
||||
isRoundedRect: self.contentNode.clipStyle == .roundedRect || storyPresentationParams.forceRoundedRect
|
||||
)),
|
||||
environment: {},
|
||||
containerSize: indicatorSize
|
||||
|
@ -126,10 +126,17 @@ final class PeerInfoAvatarTransformContainerNode: ASDisplayNode {
|
||||
progress: storyProgress
|
||||
)
|
||||
}
|
||||
|
||||
var isForum = false
|
||||
if let peer, let channel = peer as? TelegramChannel, channel.isForum {
|
||||
isForum = true
|
||||
}
|
||||
|
||||
self.avatarNode.setStoryStats(storyStats: storyStats, presentationParams: AvatarNode.StoryPresentationParams(
|
||||
colors: colors,
|
||||
lineWidth: 3.0,
|
||||
inactiveLineWidth: 1.5
|
||||
inactiveLineWidth: 1.5,
|
||||
forceRoundedRect: isForum
|
||||
), transition: Transition(transition))
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user