summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Preston <johnprestonmail@gmail.com>2023-09-22 20:59:37 +0400
committerJohn Preston <johnprestonmail@gmail.com>2023-09-22 20:59:37 +0400
commita6df03d990ac2dd0f37f1b7527ee5395a784b39f (patch)
treed21cfdb5a80388eeb1ee91f11682464524f63f0e
parent16b188126826f5d2de30769b139fc1b6343ec391 (diff)
Version 4.10: Fix channel stories phrases.v4.10.0
-rw-r--r--Telegram/Resources/langs/lang.strings1
-rw-r--r--Telegram/SourceFiles/dialogs/ui/dialogs_stories_content.cpp15
2 files changed, 12 insertions, 4 deletions
diff --git a/Telegram/Resources/langs/lang.strings b/Telegram/Resources/langs/lang.strings
index ea91c9631f..35a4324ef9 100644
--- a/Telegram/Resources/langs/lang.strings
+++ b/Telegram/Resources/langs/lang.strings
@@ -2416,6 +2416,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
"lng_context_open_gif" = "Open GIF";
"lng_context_save_gif" = "Save GIF";
"lng_context_delete_gif" = "Delete GIF";
+"lng_context_open_channel" = "Open Channel";
"lng_context_attached_stickers" = "Attached Stickers";
"lng_context_to_msg" = "Go To Message";
"lng_context_reply_msg" = "Reply";
diff --git a/Telegram/SourceFiles/dialogs/ui/dialogs_stories_content.cpp b/Telegram/SourceFiles/dialogs/ui/dialogs_stories_content.cpp
index b4df07d994..68368ebaa8 100644
--- a/Telegram/SourceFiles/dialogs/ui/dialogs_stories_content.cpp
+++ b/Telegram/SourceFiles/dialogs/ui/dialogs_stories_content.cpp
@@ -512,12 +512,19 @@ void FillSourceMenu(
controller->showSection(Info::Stories::Make(peer));
}, &st::menuIconStoriesSavedSection);
} else {
- add(tr::lng_profile_send_message(tr::now), [=] {
+ const auto channel = peer->isChannel();
+ const auto showHistoryText = channel
+ ? tr::lng_context_open_channel(tr::now)
+ : tr::lng_profile_send_message(tr::now);
+ add(showHistoryText, [=] {
controller->showPeerHistory(peer);
- }, &st::menuIconChatBubble);
- add(tr::lng_context_view_profile(tr::now), [=] {
+ }, channel ? &st::menuIconChannel : &st::menuIconChatBubble);
+ const auto viewProfileText = channel
+ ? tr::lng_context_view_channel(tr::now)
+ : tr::lng_context_view_profile(tr::now);
+ add(viewProfileText, [=] {
controller->showPeerInfo(peer);
- }, &st::menuIconProfile);
+ }, channel ? &st::menuIconInfo : &st::menuIconProfile);
const auto in = [&](Data::StorySourcesList list) {
return ranges::contains(
owner->stories().sources(list),