Various improvements

This commit is contained in:
Ilya Laktyushin
2023-07-15 03:08:32 +02:00
parent ae60c2be8b
commit d88cd4f7c4
6 changed files with 93 additions and 33 deletions

View File

@@ -3127,6 +3127,12 @@ public final class DrawingToolsInteraction {
if let entityView = self.entitiesView.getView(for: entity.uuid) {
if let textEntityView = entityView as? DrawingTextEntityView {
textEntityView.beginEditing(accessoryView: self.textEditAccessoryView)
textEntityView.replaceWithImage = { [weak self] image, isSticker in
if let self {
self.insertEntity(DrawingStickerEntity(content: .image(image, isSticker ? .sticker : .rectangle)), scale: 2.5)
}
}
} else {
if self.isVideo {
entityView.seek(to: 0.0)