Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Q
qgroundcontrol
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Valentin Platzgummer
qgroundcontrol
Commits
a701991c
Commit
a701991c
authored
7 years ago
by
Patrick José Pereira
Browse files
Options
Downloads
Patches
Plain Diff
Move code to use QT_VERSION_CHECK
Signed-off-by:
Patrick José Pereira
<
patrickelectric@gmail.com
>
parent
09a9deb3
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/QtLocationPlugin/QGeoTiledMappingManagerEngineQGC.cpp
+7
-7
7 additions, 7 deletions
src/QtLocationPlugin/QGeoTiledMappingManagerEngineQGC.cpp
src/QtLocationPlugin/QGeoTiledMappingManagerEngineQGC.h
+4
-4
4 additions, 4 deletions
src/QtLocationPlugin/QGeoTiledMappingManagerEngineQGC.h
with
11 additions
and
11 deletions
src/QtLocationPlugin/QGeoTiledMappingManagerEngineQGC.cpp
+
7
−
7
View file @
a701991c
...
...
@@ -50,11 +50,11 @@
#include
<QtLocation/private/qgeocameracapabilities_p.h>
#include
<QtLocation/private/qgeomaptype_p.h>
#if QT_VERSION <
0x050500
#if QT_VERSION <
QT_VERSION_CHECK(5, 5, 0)
#include
<QtLocation/private/qgeotiledmapdata_p.h>
#else
#include
<QtLocation/private/qgeotiledmap_p.h>
#if QT_VERSION >=
0x050600
#if QT_VERSION >=
QT_VERSION_CHECK(5, 6, 0)
#include
<QtLocation/private/qgeofiletilecache_p.h>
#else
#include
<QtLocation/private/qgeotilecache_p.h>
...
...
@@ -64,7 +64,7 @@
#include
<QDir>
#include
<QStandardPaths>
#if QT_VERSION >=
0x050500
#if QT_VERSION >=
QT_VERSION_CHECK(5, 5, 0)
//-----------------------------------------------------------------------------
QGeoTiledMapQGC
::
QGeoTiledMapQGC
(
QGeoTiledMappingManagerEngine
*
engine
,
QObject
*
parent
)
:
QGeoTiledMap
(
engine
,
parent
)
...
...
@@ -165,7 +165,7 @@ QGeoTiledMappingManagerEngineQGC::QGeoTiledMappingManagerEngineQGC(const QVarian
getQGCMapEngine
()
->
setUserAgent
(
parameters
.
value
(
QStringLiteral
(
"useragent"
)).
toString
().
toLatin1
());
}
#if QT_VERSION >=
0x050500
#if QT_VERSION >=
QT_VERSION_CHECK(5, 5, 0)
_setCache
(
parameters
);
#endif
...
...
@@ -180,7 +180,7 @@ QGeoTiledMappingManagerEngineQGC::~QGeoTiledMappingManagerEngineQGC()
{
}
#if QT_VERSION <
0x050500
#if QT_VERSION <
QT_VERSION_CHECK(5, 5, 0)
//-----------------------------------------------------------------------------
QGeoMapData
*
QGeoTiledMappingManagerEngineQGC
::
createMapData
()
...
...
@@ -199,7 +199,7 @@ QGeoTiledMappingManagerEngineQGC::createMap()
#endif
#if QT_VERSION >=
0x050500
#if QT_VERSION >=
QT_VERSION_CHECK(5, 5, 0)
//-----------------------------------------------------------------------------
void
QGeoTiledMappingManagerEngineQGC
::
_setCache
(
const
QVariantMap
&
parameters
)
...
...
@@ -242,7 +242,7 @@ QGeoTiledMappingManagerEngineQGC::_setCache(const QVariantMap ¶meters)
if
(
memLimit
>
1024
*
1024
*
1024
)
memLimit
=
1024
*
1024
*
1024
;
//-- Disable Qt's disk cache (sort of)
#if QT_VERSION >=
0x050600
#if QT_VERSION >=
QT_VERSION_CHECK(5, 6, 0)
QAbstractGeoTileCache
*
pTileCache
=
new
QGeoFileTileCache
(
cacheDir
);
setTileCache
(
pTileCache
);
#else
...
...
This diff is collapsed.
Click to expand it.
src/QtLocationPlugin/QGeoTiledMappingManagerEngineQGC.h
+
4
−
4
View file @
a701991c
...
...
@@ -48,12 +48,12 @@
#define QGEOTILEDMAPPINGMANAGERENGINEQGC_H
#include
<QtLocation/QGeoServiceProvider>
#if QT_VERSION >=
0x050500
#if QT_VERSION >=
QT_VERSION_CHECK(5, 5, 0)
#include
<QtLocation/private/qgeotiledmap_p.h>
#endif
#include
<QtLocation/private/qgeotiledmappingmanagerengine_p.h>
#if QT_VERSION >=
0x050500
#if QT_VERSION >=
QT_VERSION_CHECK(5, 5, 0)
class
QGeoTiledMapQGC
:
public
QGeoTiledMap
{
Q_OBJECT
...
...
@@ -70,13 +70,13 @@ class QGeoTiledMappingManagerEngineQGC : public QGeoTiledMappingManagerEngine
public:
QGeoTiledMappingManagerEngineQGC
(
const
QVariantMap
&
parameters
,
QGeoServiceProvider
::
Error
*
error
,
QString
*
errorString
);
~
QGeoTiledMappingManagerEngineQGC
();
#if QT_VERSION <
0x050500
#if QT_VERSION <
QT_VERSION_CHECK(5, 5, 0)
QGeoMapData
*
createMapData
();
#else
QGeoMap
*
createMap
();
#endif
private:
#if QT_VERSION >=
0x050500
#if QT_VERSION >=
QT_VERSION_CHECK(5, 5, 0)
void
_setCache
(
const
QVariantMap
&
parameters
);
#endif
};
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment