From: Till Theato Date: Sun, 12 Dec 2010 19:02:27 +0000 (+0000) Subject: Add option to allow the parameters to stay enabled when the effect is disabled. X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=7f07524f6ade809409b815024fd15109c85618f6;p=kdenlive Add option to allow the parameters to stay enabled when the effect is disabled. Using the parameters with the effect disabled can be useful for example for colorpicking (white balance, bluescreen). svn path=/trunk/kdenlive/; revision=5169 --- diff --git a/src/effectstackedit.cpp b/src/effectstackedit.cpp index 3d24f472..fa8c2034 100644 --- a/src/effectstackedit.cpp +++ b/src/effectstackedit.cpp @@ -163,7 +163,7 @@ void EffectStackEdit::updateParameter(const QString &name, const QString &value) if (name == "disable") { // if effect is disabled, disable parameters widget - setEnabled(value.toInt() == 0); + setEnabled(value.toInt() == 0 || !KdenliveSettings::disable_effect_parameters()); if (KdenliveSettings::on_monitor_effects()) { // effect disabled, hide monitor scene if any QDomNodeList namenode = m_params.elementsByTagName("parameter"); @@ -175,7 +175,7 @@ void EffectStackEdit::updateParameter(const QString &name, const QString &value) QString paramName = i18n(na.toElement().text().toUtf8().data()); paramName.append("geometry"); GeometryWidget *geometry = ((GeometryWidget*)m_valueItems.value(paramName)); - geometry->slotShowScene(value.toInt() == 0); + geometry->slotShowScene(value.toInt() == 0 || !KdenliveSettings::disable_effect_parameters()); } } } @@ -200,8 +200,8 @@ void EffectStackEdit::transferParamDesc(const QDomElement d, int pos, int in, in const int minFrame = e.attribute("start").toInt(); const int maxFrame = e.attribute("end").toInt(); - bool disabled = d.attribute("disable") == "1"; - setEnabled(!disabled); + bool disable = d.attribute("disable") == "1" && KdenliveSettings::disable_effect_parameters(); + setEnabled(!disable); for (int i = 0; i < namenode.count() ; i++) { @@ -283,7 +283,7 @@ void EffectStackEdit::transferParamDesc(const QDomElement d, int pos, int in, in connect(pl, SIGNAL(parameterChanged()), this, SLOT(collectAllParameters())); } else if (type == "geometry") { if (KdenliveSettings::on_monitor_effects()) { - GeometryWidget *geometry = new GeometryWidget(m_monitor, m_timecode, pos, isEffect, disabled, this); + GeometryWidget *geometry = new GeometryWidget(m_monitor, m_timecode, pos, isEffect, disable, this); // connect this before setupParam to make sure the monitor scene shows up at startup connect(geometry, SIGNAL(checkMonitorPosition(int)), this, SIGNAL(checkMonitorPosition(int))); connect(geometry, SIGNAL(parameterChanged()), this, SLOT(collectAllParameters())); diff --git a/src/kdenlivesettings.kcfg b/src/kdenlivesettings.kcfg index ddcb1052..c0609add 100644 --- a/src/kdenlivesettings.kcfg +++ b/src/kdenlivesettings.kcfg @@ -59,6 +59,11 @@ true + + + + true + diff --git a/src/widgets/configmisc_ui.ui b/src/widgets/configmisc_ui.ui index 44d030bb..2e7c451d 100644 --- a/src/widgets/configmisc_ui.ui +++ b/src/widgets/configmisc_ui.ui @@ -6,8 +6,8 @@ 0 0 - 389 - 304 + 394 + 321 @@ -32,7 +32,7 @@ - + Default Durations @@ -100,7 +100,7 @@ - + Qt::Vertical @@ -127,7 +127,7 @@ - + Automatically import image sequences @@ -148,6 +148,13 @@ + + + + Disable parameters when the effect is disabled + + +