1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2025-06-27 11:39:16 +02:00

Improved error reporting.

Cosmetics.
This commit is contained in:
2017-01-02 23:01:50 +01:00
parent ea178d1acb
commit 3e340ab941
4 changed files with 111 additions and 104 deletions

View File

@ -462,7 +462,7 @@ void GraphView::useOpenGL(bool use)
#ifdef Q_OS_WIN32
if (QSysInfo::WindowsVersion >= QSysInfo::WV_VISTA)
#endif // Q_OS_WIN32
setViewport(new OPENGL_WIDGET);
setViewport(new OPENGL_WIDGET);
} else
setViewport(new QWidget);
}

View File

@ -135,8 +135,15 @@ void GUI::loadPOIs()
else
list = globalDir.entryInfoList(QStringList(), QDir::Files);
for (int i = 0; i < list.size(); ++i)
_poi->loadFile(list.at(i).absoluteFilePath());
for (int i = 0; i < list.size(); ++i) {
if (!_poi->loadFile(list.at(i).absoluteFilePath())) {
fprintf(stderr, "Error loading POI file: %s: %s\n",
qPrintable(list.at(i).fileName()),
qPrintable(_poi->errorString()));
if (_poi->errorLine())
fprintf(stderr, "Line: %d\n", _poi->errorLine());
}
}
}
void GUI::createMapActions()

View File

@ -712,7 +712,7 @@ void PathView::useOpenGL(bool use)
#ifdef Q_OS_WIN32
if (QSysInfo::WindowsVersion >= QSysInfo::WV_VISTA)
#endif // Q_OS_WIN32
setViewport(new OPENGL_WIDGET);
setViewport(new OPENGL_WIDGET);
} else
setViewport(new QWidget);
}