diff --git a/Telegram/SourceFiles/core/click_handler_types.cpp b/Telegram/SourceFiles/core/click_handler_types.cpp index 8f570fe5b..255fd1faf 100644 --- a/Telegram/SourceFiles/core/click_handler_types.cpp +++ b/Telegram/SourceFiles/core/click_handler_types.cpp @@ -188,9 +188,15 @@ void MentionClickHandler::onClick(ClickContext context) const { const auto button = context.button; if (button == Qt::LeftButton || button == Qt::MiddleButton) { const auto my = context.other.value(); - if (const auto controller = my.sessionWindow.get()) { + const auto controller = my.sessionWindow.get(); + const auto use = controller + ? controller + : Core::App().activeWindow() + ? Core::App().activeWindow()->sessionController() + : nullptr; + if (use) { using Info = Window::SessionNavigation::PeerByLinkInfo; - controller->showPeerByLink(Info{ + use->showPeerByLink(Info{ .usernameOrId = _tag.mid(1), .resolveType = Window::ResolveType::Mention, }); diff --git a/Telegram/lib_ui b/Telegram/lib_ui index 7aedf7703..b90d7ee27 160000 --- a/Telegram/lib_ui +++ b/Telegram/lib_ui @@ -1 +1 @@ -Subproject commit 7aedf7703fdf24c11375b7e67c2a6d9e16b0008b +Subproject commit b90d7ee27a85904c49e0f495c11b722b23db8fd2