2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-09-01 06:55:58 +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

@@ -69,21 +69,32 @@ public:
struct ColumnLayout {
int bodyWidth;
int dialogsWidth;
int chatWidth;
Adaptive::WindowLayout windowLayout;
};
ColumnLayout computeColumnLayout();
ColumnLayout computeColumnLayout() const;
int dialogsSmallColumnWidth() const;
bool provideChatWidth(int requestedWidth);
bool canProvideChatWidth(int requestedWidth) const;
void provideChatWidth(int requestedWidth);
base::Variable<float64> &dialogsWidthRatio() {
return _dialogsWidthRatio;
}
const base::Variable<float64> &dialogsWidthRatio() const {
return _dialogsWidthRatio;
}
base::Variable<bool> &dialogsListFocused() {
return _dialogsListFocused;
}
const base::Variable<bool> &dialogsListFocused() const {
return _dialogsListFocused;
}
base::Variable<bool> &dialogsListDisplayForced() {
return _dialogsListDisplayForced;
}
const base::Variable<bool> &dialogsListDisplayForced() const {
return _dialogsListDisplayForced;
}
private:
gsl::not_null<MainWindow*> _window;