mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 14:20:20 +00:00
UI and theme improvements
This commit is contained in:
@@ -2210,14 +2210,25 @@ class ChatTextInputPanelNode: ChatInputPanelNode, ASEditableTextNodeDelegate {
|
||||
let backgroundView = UIImageView(image: backgroundImage)
|
||||
backgroundView.frame = self.textInputBackgroundNode.frame
|
||||
|
||||
//let previousTintColor = textInputNode.view.tintColor
|
||||
//textInputNode.view.tintColor = .clear
|
||||
func updateIsCaretHidden(view: UIView, isHidden: Bool) {
|
||||
if String(describing: type(of: view)).contains("TextSelectionView") {
|
||||
view.isHidden = isHidden
|
||||
} else {
|
||||
for subview in view.subviews {
|
||||
updateIsCaretHidden(view: subview, isHidden: isHidden)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
updateIsCaretHidden(view: textInputNode.view, isHidden: true)
|
||||
|
||||
guard let contentView = textInputNode.view.snapshotView(afterScreenUpdates: true) else {
|
||||
//textInputNode.view.tintColor = previousTintColor
|
||||
updateIsCaretHidden(view: textInputNode.view, isHidden: false)
|
||||
return nil
|
||||
}
|
||||
//textInputNode.view.tintColor = previousTintColor
|
||||
|
||||
updateIsCaretHidden(view: textInputNode.view, isHidden: false)
|
||||
|
||||
contentView.frame = textInputNode.frame
|
||||
|
||||
return ChatMessageTransitionNode.Source.TextInput(
|
||||
|
||||
Reference in New Issue
Block a user