Commit 8bf52f35 authored by Paul Lemire's avatar Paul Lemire
Browse files

QTextureLoader: reset target and format on source change



Could otherwise prevent reloading the content of the texture
when the generator/source changes

Change-Id: I5cf3389792032ba7a85a111f04dd4670a3091683
Reviewed-by: Mike Krus's avatarMike Krus <mike.krus@kdab.com>
parent 3c9a56d4
......@@ -1483,6 +1483,11 @@ void QTextureLoader::setSource(const QUrl& source)
Q_D(QTextureLoader);
if (source != d->m_source) {
d->m_source = source;
// Reset target and format
d->m_target = TargetAutomatic;
setFormat(NoFormat);
d->updateGenerator();
const bool blocked = blockNotifications(true);
emit sourceChanged(source);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment