2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-30 22:16:14 +00:00

Open specific chat only in one window.

This commit is contained in:
John Preston
2022-01-04 19:36:33 +03:00
parent 54247cd11b
commit 18e6e2da9e
16 changed files with 187 additions and 103 deletions

View File

@@ -730,7 +730,10 @@ void MainWindow::initGeometry() {
if (initGeometryFromSystem()) {
return;
}
const auto geometry = countInitialGeometry(positionFromSettings());
// #TODO windows
const auto geometry = countInitialGeometry(isPrimary()
? positionFromSettings()
: Core::WindowPosition());
DEBUG_LOG(("Window Pos: Setting first %1, %2, %3, %4"
).arg(geometry.x()
).arg(geometry.y()
@@ -813,6 +816,7 @@ void MainWindow::savePosition(Qt::WindowState state) {
if (state == Qt::WindowMinimized
|| !isVisible()
|| !isPrimary() // #TODO windows
|| !positionInited()) {
return;
}