Implement copy restriction and send as peer

This commit is contained in:
Ilya Laktyushin
2021-11-05 21:45:48 +04:00
parent 003d263ebd
commit 1a717fbda5
37 changed files with 1004 additions and 216 deletions

View File

@@ -578,7 +578,7 @@ class ChatMessageTextBubbleContentNode: ChatMessageBubbleContentNode {
override func updateIsExtractedToContextPreview(_ value: Bool) {
if value {
if self.textSelectionNode == nil, let item = self.item, let rootNode = item.controllerInteraction.chatControllerNode() {
if self.textSelectionNode == nil, let item = self.item, !item.message.isCopyProtected(), let rootNode = item.controllerInteraction.chatControllerNode() {
let selectionColor: UIColor
let knobColor: UIColor
if item.message.effectivelyIncoming(item.context.account.peerId) {