feat: hotfix wysiwyg editor crashes and freezes (MESSENGER-8082)

This commit is contained in:
Frank Rotermund
2026-02-09 14:10:49 +01:00
parent e11e0475dc
commit 1ad45d21df
5 changed files with 30 additions and 4 deletions

View File

@@ -380,8 +380,12 @@ class WysiwygInputToolbarView: MXKRoomInputToolbarView, NibLoadable, HtmlRoomInp
}
private func updateToolbarHeight(wysiwygHeight: CGFloat) {
self.heightConstraint.constant = wysiwygHeight
toolbarViewDelegate?.roomInputToolbarView?(self, heightDidChanged: wysiwygHeight, completion: nil)
// bwi: #8116 fix freeze caused by rouding errors
if (wysiwygHeight - self.heightConstraint.constant).magnitude > 1 {
self.heightConstraint.constant = wysiwygHeight
toolbarViewDelegate?.roomInputToolbarView?(self, heightDidChanged: wysiwygHeight, completion: nil)
}
}
private func sendWysiwygMessage(content: WysiwygComposerContent) {