2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-09-02 23:45:44 +00:00

adaptive layout starts after 1366px window, langs updated, hiding tooltip on window deactivation

This commit is contained in:
John Preston
2016-02-22 10:01:10 +03:00
parent 90d104cf61
commit 7de5e24df5
11 changed files with 28 additions and 20 deletions

View File

@@ -1229,12 +1229,10 @@ void Window::resizeEvent(QResizeEvent *e) {
if (!title) return;
Adaptive::Layout layout = Adaptive::OneColumnLayout;
if (width() >= st::adaptiveNormalWidth) {
if (width() - chatsListWidth(width()) >= st::historyMaxWidth) {
layout = Adaptive::WideLayout;
} else {
layout = Adaptive::NormalLayout;
}
if (width() > st::adaptiveWideWidth) {
layout = Adaptive::WideLayout;
} else if (width() >= st::adaptiveNormalWidth) {
layout = Adaptive::NormalLayout;
}
if (layout != Global::AdaptiveLayout()) {
Global::SetAdaptiveLayout(layout);