aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Baptiste Mardelle <[email protected]>2016-04-13 20:59:59 +0200
committerJean-Baptiste Mardelle <[email protected]>2016-04-14 22:53:58 +0200
commitf59bcead177fa84505686f39c75ee863c4462604 (patch)
tree6051287948ea0fc882e518c4a98b0b78992eb78a
parent903f6d9b0ab09fa7edc5cd71649b53cdbe4d5918 (diff)
Fix converting of old volume effect with constant value
-rw-r--r--src/doc/documentvalidator.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/doc/documentvalidator.cpp b/src/doc/documentvalidator.cpp
index 0d36671..f86c70f 100644
--- a/src/doc/documentvalidator.cpp
+++ b/src/doc/documentvalidator.cpp
@@ -1545,9 +1545,12 @@ void DocumentValidator::convertKeyframeEffect(QDomElement effect, QStringList pa
{
QLocale locale;
int in = effect.attribute(QStringLiteral("in")).toInt() - offset;
- int out = effect.attribute(QStringLiteral("out")).toInt() - offset;
values.insert(in, locale.toDouble(EffectsList::property(effect, params.at(0))));
- values.insert(out, locale.toDouble(EffectsList::property(effect, params.at(1))));
+ QString endValue = EffectsList::property(effect, params.at(1));
+ if (!endValue.isEmpty()) {
+ int out = effect.attribute(QStringLiteral("out")).toInt() - offset;
+ values.insert(out, locale.toDouble(endValue));
+ }
}
void DocumentValidator::updateProducerInfo(QDomElement prod, const QDomElement source)