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

Enable third column by default in Mac App Store build.

This commit is contained in:
John Preston
2020-02-15 22:45:50 +04:00
parent 3bb9e8c7eb
commit 82aa64ca0a
4 changed files with 24 additions and 6 deletions

View File

@@ -398,15 +398,21 @@ void MainWindow::initSize() {
? primaryScreen->availableGeometry()
: QRect(0, 0, st::windowDefaultWidth, st::windowDefaultHeight);
bool maximized = false;
const auto initialWidth = Main::Settings::ThirdColumnByDefault()
? st::windowBigDefaultWidth
: st::windowDefaultWidth;
const auto initialHeight = Main::Settings::ThirdColumnByDefault()
? st::windowBigDefaultHeight
: st::windowDefaultHeight;
auto geometry = QRect(
available.x() + std::max(
(available.width() - st::windowDefaultWidth) / 2,
(available.width() - initialWidth) / 2,
0),
available.y() + std::max(
(available.height() - st::windowDefaultHeight) / 2,
(available.height() - initialHeight) / 2,
0),
st::windowDefaultWidth,
st::windowDefaultHeight);
initialWidth,
initialHeight);
if (position.w && position.h) {
for (auto screen : QGuiApplication::screens()) {
if (position.moncrc == screenNameChecksum(screen->name())) {