mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-11-25 01:22:41 +00:00
Various fixes
This commit is contained in:
parent
37e752c78f
commit
cbe32ac94b
@ -439,7 +439,7 @@ final class LocalizationListControllerNode: ViewControllerTracingNode {
|
||||
}
|
||||
var existingIds = Set<String>()
|
||||
|
||||
var showTranslate = true
|
||||
var showTranslate = false
|
||||
var ignoredLanguages: [String] = []
|
||||
if let translationSettings = sharedData.entries[ApplicationSpecificSharedDataKeys.translationSettings]?.get(TranslationSettings.self) {
|
||||
showTranslate = translationSettings.showTranslate
|
||||
|
||||
@ -186,7 +186,7 @@ class ChatMessageInstantVideoBubbleContentNode: ChatMessageBubbleContentNode {
|
||||
|
||||
let automaticDownload = shouldDownloadMediaAutomatically(settings: item.controllerInteraction.automaticMediaDownloadSettings, peerType: item.associatedData.automaticDownloadPeerType, networkType: item.associatedData.automaticDownloadNetworkType, authorPeerId: item.message.author?.id, contactsPeerIds: item.associatedData.contactsPeerIds, media: selectedFile!)
|
||||
|
||||
let (_, refineLayout) = interactiveFileLayout(ChatMessageInteractiveFileNode.Arguments(
|
||||
let (initialWidth, refineLayout) = interactiveFileLayout(ChatMessageInteractiveFileNode.Arguments(
|
||||
context: item.context,
|
||||
presentationData: item.presentationData,
|
||||
message: item.message,
|
||||
@ -239,19 +239,19 @@ class ChatMessageInstantVideoBubbleContentNode: ChatMessageBubbleContentNode {
|
||||
|
||||
let contentProperties = ChatMessageBubbleContentProperties(hidesSimpleAuthorHeader: false, headerSpacing: 0.0, hidesBackground: .never, forceFullCorners: false, forceAlignment: .none, shareButtonOffset: isExpanded ? nil : CGPoint(x: displaySize.width + 4.0, y: -25.0), hidesHeaders: !isExpanded, avatarOffset: !isExpanded && isPlaying ? -100.0 : 0.0)
|
||||
|
||||
let width = videoFrame.width + 2.0
|
||||
let videoFrameWidth = videoFrame.width + 2.0
|
||||
|
||||
return (contentProperties, nil, width, { constrainedSize, position in
|
||||
var refinedWidth = videoFrame.width + 2.0
|
||||
return (contentProperties, nil, initialWidth, { constrainedSize, position in
|
||||
var refinedWidth = videoFrameWidth
|
||||
var finishLayout: ((CGFloat) -> (CGSize, (Bool, ListViewItemUpdateAnimation, ListViewItemApply?) -> Void))?
|
||||
|
||||
if isExpanded || !didSetupFileNode {
|
||||
(refinedWidth, finishLayout) = refineLayout(CGSize(width: constrainedSize.width - layoutConstants.file.bubbleInsets.left - layoutConstants.file.bubbleInsets.right, height: constrainedSize.height))
|
||||
(refinedWidth, finishLayout) = refineLayout(CGSize(width: constrainedSize.width - layoutConstants.file.bubbleInsets.left - layoutConstants.file.bubbleInsets.right - 44.0, height: constrainedSize.height))
|
||||
refinedWidth += layoutConstants.file.bubbleInsets.left + layoutConstants.file.bubbleInsets.right
|
||||
}
|
||||
|
||||
if !isExpanded {
|
||||
refinedWidth = videoFrame.width + 2.0
|
||||
refinedWidth = videoFrameWidth
|
||||
}
|
||||
|
||||
return (refinedWidth, { boundingWidth in
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user