Merge remote-tracking branch 'mine/CGAL_Qt-Fix_deprecation_warnings-GF' into CGAL_Qt-Fix_deprecation_warnings-4.14-GF

This commit is contained in:
Maxime Gimeno 2019-07-11 10:23:39 +02:00
commit 272b4360d0
1 changed files with 6 additions and 0 deletions

View File

@ -459,7 +459,13 @@ void DemosMainWindow::readState(QString groupname, Options /*what_to_save*/)
resize(settings.value("size", this->size()).toSize());
QPoint pos = settings.value("pos", this->pos()).toPoint();
#if QT_VERSION >= QT_VERSION_CHECK(5, 10, 0)
if(QGuiApplication::screenAt(pos)) {
#else
QDesktopWidget* desktop = qApp->desktop();
if(desktop->availableGeometry(pos).contains(pos)) {
#endif
move(pos);
}
QByteArray mainWindowState = settings.value("state").toByteArray();