2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 14:45:14 +00:00

Fix enabling emoji sidebar from a small window.

Extend the window size after the tabbedSelectorSectionEnabled flag
is already set to true. Otherwise we extend the window and switch
to a normal from single column layout before showing the sidebar.
This commit is contained in:
John Preston
2017-05-17 14:50:00 +03:00
parent 966dcd5509
commit 9f7c45e35c
4 changed files with 42 additions and 20 deletions

View File

@@ -3787,11 +3787,12 @@ void HistoryWidget::toggleTabbedSelectorMode() {
updateTabbedSelectorSectionShown();
recountChatWidth();
updateControlsGeometry();
} else if (_controller->provideChatWidth(minimalWidthForTabbedSelectorSection())) {
} else if (_controller->canProvideChatWidth(minimalWidthForTabbedSelectorSection())) {
if (!AuthSession::Current().data().tabbedSelectorSectionEnabled()) {
AuthSession::Current().data().setTabbedSelectorSectionEnabled(true);
AuthSession::Current().saveDataDelayed(kSaveTabbedSelectorSectionTimeoutMs);
}
_controller->provideChatWidth(minimalWidthForTabbedSelectorSection());
updateTabbedSelectorSectionShown();
recountChatWidth();
updateControlsGeometry();