1
0
Fork 0

Launcher: Fix compilation with Qt < 5.6

This commit is contained in:
James Turner 2020-04-21 16:34:24 +01:00
parent b85048db2d
commit 858fc6ea01

View file

@ -83,8 +83,11 @@ QSGNode *ThumbnailImageItem::updatePaintNode(QSGNode* oldNode, QQuickItem::Updat
textureNode = new QSGSimpleTextureNode; textureNode = new QSGSimpleTextureNode;
textureNode->setOwnsTexture(true); textureNode->setOwnsTexture(true);
} }
#if QT_VERSION >= QT_VERSION_CHECK(5, 6, 0)
QSGTexture* tex = window()->createTextureFromImage(m_image, QQuickWindow::TextureIsOpaque); QSGTexture* tex = window()->createTextureFromImage(m_image, QQuickWindow::TextureIsOpaque);
#else
QSGTexture* tex = window()->createTextureFromImage(m_image);
#endif
textureNode->setTexture(tex); textureNode->setTexture(tex);
textureNode->markDirty(QSGBasicGeometryNode::DirtyMaterial); textureNode->markDirty(QSGBasicGeometryNode::DirtyMaterial);
m_imageDirty = false; m_imageDirty = false;