mirror of
https://github.com/tumic0/GPXSee.git
synced 2025-01-31 09:05:14 +01:00
Added workaround for broken Qt SVG image plugin colliding with the MVT plugin
This commit is contained in:
parent
029f36a5da
commit
bac55e317b
@ -135,7 +135,9 @@ bool MBTilesMap::getTileSize()
|
|||||||
|
|
||||||
QByteArray data = query.value(0).toByteArray();
|
QByteArray data = query.value(0).toByteArray();
|
||||||
QBuffer buffer(&data);
|
QBuffer buffer(&data);
|
||||||
QImageReader reader(&buffer);
|
/* Explicitly specify the image plugin in case of vector tiles
|
||||||
|
(QTBUG-119910 workaround) */
|
||||||
|
QImageReader reader(&buffer, _scalable ? QByteArray("mvt") : QByteArray());
|
||||||
QSize tileSize(reader.size());
|
QSize tileSize(reader.size());
|
||||||
|
|
||||||
if (!tileSize.isValid() || tileSize.width() != tileSize.height()) {
|
if (!tileSize.isValid() || tileSize.width() != tileSize.height()) {
|
||||||
@ -215,9 +217,9 @@ MBTilesMap::MBTilesMap(const QString &fileName, QObject *parent)
|
|||||||
return;
|
return;
|
||||||
if (!getBounds())
|
if (!getBounds())
|
||||||
return;
|
return;
|
||||||
|
getTileFormat();
|
||||||
if (!getTileSize())
|
if (!getTileSize())
|
||||||
return;
|
return;
|
||||||
getTileFormat();
|
|
||||||
getTilePixelRatio();
|
getTilePixelRatio();
|
||||||
getName();
|
getName();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user