1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2025-01-31 09:05:14 +01:00

Code cleanup

This commit is contained in:
Martin Tůma 2016-12-10 11:50:53 +01:00
parent 7e8530555d
commit 0cbf79870b
3 changed files with 10 additions and 10 deletions

View File

@ -6,9 +6,9 @@
#include <QPixmapCache> #include <QPixmapCache>
#if QT_VERSION < QT_VERSION_CHECK(5, 4, 0) #if QT_VERSION < QT_VERSION_CHECK(5, 4, 0)
#include <QGLFormat> #include <QGLFormat>
#else // QT 5 #else // QT 5.4
#include <QSurfaceFormat> #include <QSurfaceFormat>
#endif // QT 5 #endif // QT 5.4
#include "gui.h" #include "gui.h"
#include "app.h" #include "app.h"
@ -31,11 +31,11 @@ App::App(int &argc, char **argv) : QApplication(argc, argv),
QGLFormat fmt; QGLFormat fmt;
fmt.setSamples(4); fmt.setSamples(4);
QGLFormat::setDefaultFormat(fmt); QGLFormat::setDefaultFormat(fmt);
#else #else // QT 5.4
QSurfaceFormat fmt; QSurfaceFormat fmt;
fmt.setSamples(4); fmt.setSamples(4);
QSurfaceFormat::setDefaultFormat(fmt); QSurfaceFormat::setDefaultFormat(fmt);
#endif #endif // QT 5.4
QPixmapCache::setCacheLimit(65536); QPixmapCache::setCacheLimit(65536);

View File

@ -5,9 +5,9 @@
#include <QPaintDevice> #include <QPaintDevice>
#if QT_VERSION < QT_VERSION_CHECK(5, 4, 0) #if QT_VERSION < QT_VERSION_CHECK(5, 4, 0)
#include <QGLWidget> #include <QGLWidget>
#else // QT 5 #else // QT 5.4
#include <QOpenGLWidget> #include <QOpenGLWidget>
#endif // QT 5 #endif // QT 5.4
#include <QSysInfo> #include <QSysInfo>
#include "config.h" #include "config.h"
#include "axisitem.h" #include "axisitem.h"
@ -468,9 +468,9 @@ void GraphView::useOpenGL(bool use)
#endif // Q_OS_WIN32 #endif // Q_OS_WIN32
#if QT_VERSION < QT_VERSION_CHECK(5, 4, 0) #if QT_VERSION < QT_VERSION_CHECK(5, 4, 0)
setViewport(new QGLWidget); setViewport(new QGLWidget);
#else // QT 5 #else // QT 5.4
setViewport(new QOpenGLWidget); setViewport(new QOpenGLWidget);
#endif // QT 5 #endif // QT 5.4
} else } else
setViewport(new QWidget); setViewport(new QWidget);
} }

View File

@ -718,9 +718,9 @@ void PathView::useOpenGL(bool use)
#endif // Q_OS_WIN32 #endif // Q_OS_WIN32
#if QT_VERSION < QT_VERSION_CHECK(5, 4, 0) #if QT_VERSION < QT_VERSION_CHECK(5, 4, 0)
setViewport(new QGLWidget); setViewport(new QGLWidget);
#else // QT 5 #else // QT 5.4
setViewport(new QOpenGLWidget); setViewport(new QOpenGLWidget);
#endif // QT 5 #endif // QT 5.4
} else } else
setViewport(new QWidget); setViewport(new QWidget);
} }