From bd8b90055ec3677a5e491992328997183fb4a9c8 Mon Sep 17 00:00:00 2001 From: John Preston Date: Mon, 7 Nov 2022 13:14:52 +0400 Subject: [PATCH] Fix showing forum in a single-column layout. --- Telegram/SourceFiles/dialogs/dialogs_widget.cpp | 7 +++---- Telegram/SourceFiles/window/window_session_controller.cpp | 3 +++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/Telegram/SourceFiles/dialogs/dialogs_widget.cpp b/Telegram/SourceFiles/dialogs/dialogs_widget.cpp index 12f857b8e..9f1109d25 100644 --- a/Telegram/SourceFiles/dialogs/dialogs_widget.cpp +++ b/Telegram/SourceFiles/dialogs/dialogs_widget.cpp @@ -716,19 +716,18 @@ void Widget::changeOpenedSubsection( FnMut change, bool fromRight, anim::type animated) { - _a_show.stop(); - if (isHidden()) { animated = anim::type::instant; } if (animated == anim::type::normal) { + _connecting->setForceHidden(true); + _cacheUnder = grabForFolderSlideAnimation(); _showDirection = fromRight ? Window::SlideDirection::FromRight : Window::SlideDirection::FromLeft; _showAnimationType = ShowAnimation::Internal; - _connecting->setForceHidden(true); - _cacheUnder = grabForFolderSlideAnimation(); } + _a_show.stop(); change(); refreshTopBars(); updateControlsVisibility(true); diff --git a/Telegram/SourceFiles/window/window_session_controller.cpp b/Telegram/SourceFiles/window/window_session_controller.cpp index c7610d8ae..357044bae 100644 --- a/Telegram/SourceFiles/window/window_session_controller.cpp +++ b/Telegram/SourceFiles/window/window_session_controller.cpp @@ -983,6 +983,9 @@ void SessionController::openForum( if (_openedForum.current() != forum) { resetFakeUnreadWhileOpened(); } + if (forum && _activeChatEntry.current().key.peer()) { + clearSectionStack(params); + } _openedForum = forum.get(); if (_openedForum.current() == forum) { forum->forum()->destroyed(