Various Fixes

This commit is contained in:
Ilya Laktyushin
2021-11-17 18:05:34 +04:00
parent c677bba7c9
commit ce43f3df69
5 changed files with 38 additions and 12 deletions

View File

@@ -2475,17 +2475,15 @@ class ChatTextInputPanelNode: ChatInputPanelNode, ASEditableTextNodeDelegate {
let backgroundView = UIImageView(image: backgroundImage)
backgroundView.frame = self.textInputBackgroundNode.frame
func updateIsCaretHidden(view: UIView, isHidden: Bool) {
}
updateIsCaretHidden(view: textInputNode.view, isHidden: true)
let caretColor = textInputNode.textView.tintColor
textInputNode.textView.tintColor = .clear
guard let contentView = textInputNode.view.snapshotView(afterScreenUpdates: true) else {
updateIsCaretHidden(view: textInputNode.view, isHidden: false)
textInputNode.textView.tintColor = caretColor
return nil
}
updateIsCaretHidden(view: textInputNode.view, isHidden: false)
textInputNode.textView.tintColor = caretColor
contentView.frame = textInputNode.frame