Mercurial > hg > tony
diff src/main.cpp @ 572:3f0b44418a19 by-id
Toward using ModelById logic (incomplete)
author | Chris Cannam |
---|---|
date | Mon, 08 Jul 2019 14:12:08 +0100 |
parents | dd344309667f |
children | 47f96711069f |
line wrap: on
line diff
--- a/src/main.cpp Thu Jun 20 11:10:59 2019 +0100 +++ b/src/main.cpp Mon Jul 08 14:12:08 2019 +0100 @@ -27,7 +27,7 @@ #include <QMetaType> #include <QApplication> -#include <QDesktopWidget> +#include <QScreen> #include <QMessageBox> #include <QTranslator> #include <QLocale> @@ -284,8 +284,8 @@ QObject::connect(gui, SIGNAL(hideSplash()), splash, SLOT(hide())); } - QDesktopWidget *desktop = QApplication::desktop(); - QRect available = desktop->availableGeometry(); + QScreen *screen = QApplication::primaryScreen(); + QRect available = screen->availableGeometry(); int width = (available.width() * 2) / 3; int height = available.height() / 2;