diff --git a/Telegram/Resources/langs/lang.strings b/Telegram/Resources/langs/lang.strings index c2dbf4ba1b..0baa9ac0c5 100644 --- a/Telegram/Resources/langs/lang.strings +++ b/Telegram/Resources/langs/lang.strings @@ -1686,6 +1686,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL "lng_profile_changed_photo_link" = "Settings"; "lng_profile_action_short_message" = "Message"; +"lng_profile_action_short_channel" = "Channel"; "lng_profile_action_short_mute" = "Mute"; "lng_profile_action_short_unmute" = "Unmute"; "lng_profile_action_short_call" = "Call"; diff --git a/Telegram/SourceFiles/info/profile/info_profile_top_bar.cpp b/Telegram/SourceFiles/info/profile/info_profile_top_bar.cpp index ff6dd60b5d..747bc8cb07 100644 --- a/Telegram/SourceFiles/info/profile/info_profile_top_bar.cpp +++ b/Telegram/SourceFiles/info/profile/info_profile_top_bar.cpp @@ -704,6 +704,18 @@ void TopBar::setupActions(not_null controller) { }); buttons.push_back(join); _actions->add(join); + } else if (const auto channel = peer->monoforumBroadcast()) { + const auto message = Ui::CreateChild( + this, + tr::lng_profile_action_short_channel(tr::now), + st::infoProfileTopBarActionMessage); + message->setClickedCallback([=, window = controller] { + window->showPeerHistory( + channel, + Window::SectionShow::Way::Forward); + }); + buttons.push_back(message); + _actions->add(message); } { const auto notifications = Ui::CreateChild(