Commit 6b93a374 authored by Jean-Baptiste Mardelle's avatar Jean-Baptiste Mardelle
Browse files

Fix saving lift/gamma/gain effect results in broken ui.

Fixes #790
parent 838bf7a6
Pipeline #36367 passed with stage
in 29 minutes and 14 seconds
......@@ -251,6 +251,12 @@ QStringList AssetParameterModel::getKeyframableParameters() const
return paramNames;
const QString AssetParameterModel::getParam(const QString &paramName)
return m_asset->get(paramName.toUtf8().constData());
void AssetParameterModel::setParameter(const QString &name, int value, bool update)
......@@ -185,6 +185,9 @@ public:
/* @brief Returns a list of the parameter names that are keyframable */
QStringList getKeyframableParameters() const;
/** @brief Returns the current value of an effect parameter */
const QString getParam(const QString &paramName);
/* @brief Helper function to retrieve the type of a parameter given the string corresponding to it*/
static ParamType paramTypeFromStr(const QString &type);
......@@ -85,7 +85,7 @@ void AssetParameterView::setModel(const std::shared_ptr<AssetParameterModel> &mo
emit updatePresets();
connect(m_model.get(), &AssetParameterModel::dataChanged, this, &AssetParameterView::refresh);
if (paramTag.endsWith(QStringLiteral("lift_gamma_gain"))) {
if (paramTag.endsWith(QStringLiteral("lift_gamma_gain")) || m_model->getParam(QStringLiteral("mlt_service")).endsWith(QStringLiteral("lift_gamma_gain"))) {
// Special case, the colorwheel widget manages several parameters
QModelIndex index = model->index(0, 0);
auto w = AbstractParamWidget::construct(model, index, frameSize, this);
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