Commit 7c2fce1d authored by Boudewijn Rempt's avatar Boudewijn Rempt

Fix warning about uninitialized variables

parent 5122e542
......@@ -55,18 +55,21 @@ void KoResourceManager::setResource(int key, const QVariant &value)
notifyResourceChanged(sourceKey, newSourceValue);
}
} else {
} else if (m_resources.contains(key)) {
const QVariant oldValue = m_resources.value(key, QVariant());
m_resources[key] = value;
if (m_updateMediators.contains(key)) {
m_updateMediators[key]->connectResource(value);
}
if (oldValue != value) {
notifyResourceChanged(key, value);
}
}
else {
m_resources[key] = value;
notifyResourceChanged(key, value);
}
}
void KoResourceManager::notifyResourceChanged(int key, const QVariant &value)
......
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