From 89dd9c93ef1302bb904e0975df7f739e106814bc Mon Sep 17 00:00:00 2001 From: John Preston Date: Tue, 22 Aug 2023 15:06:50 +0200 Subject: [PATCH] Allow copying static emoji as well. --- Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp b/Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp index 823168554f..cb3b034ce6 100644 --- a/Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp +++ b/Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp @@ -1097,6 +1097,11 @@ void EmojiListWidget::fillRecentMenu( crl::guard(this, [=] { displaySet(setId); }), &st::menuIconShowAll); } + } else if (emoji) { + addAction(tr::lng_emoji_copy(tr::now), [=] { + const auto text = emoji->text(); + TextUtilities::SetClipboardText({ text, { text } }); + }, &st::menuIconCopy); } auto id = RecentEmojiId{ emoji }; if (custom) {