1
0
mirror of https://gitlab.com/kelteseth/ScreenPlay.git synced 2024-09-18 08:22:33 +02:00

Fix wallpaper position

This commit is contained in:
Elias Steurer 2021-05-09 11:24:33 +02:00
parent 9c7a15ee88
commit 7a428812cd

View File

@ -30,12 +30,9 @@ MacWindow::MacWindow(
if ((QApplication::screens().length() == activeScreensList.length()) && (activeScreensList.length() != 1)) {
//setupWallpaperForAllScreens();
} else if (activeScreensList.length() == 1) {
//setupWallpaperForOneScreen(activeScreensList.at(0));
auto* screen = QGuiApplication::screens().at(0);
m_window.setWidth(screen->geometry().width());
m_window.setHeight(screen->geometry().height());
auto* screen = QGuiApplication::screens().at(activeScreensList.at(0));
m_window.setGeometry(screen->geometry());
} else if (activeScreensList.length() > 1) {
//setupWallpaperForMultipleScreens(activeScreensList);
}
qmlRegisterSingletonInstance<MacWindow>("ScreenPlayWallpaper", 1, 0, "Wallpaper", this);