Commit 001b843c authored by Julius Künzel's avatar Julius Künzel
Browse files

Import keyframes dialog: simplify UI on import of a single keyframe

CCBUG: 439284
parent 107ff773
...@@ -283,6 +283,16 @@ void KeyframeImport::updateDataDisplay() ...@@ -283,6 +283,16 @@ void KeyframeImport::updateDataDisplay()
{ {
QString comboData = m_dataCombo->currentData().toString(); QString comboData = m_dataCombo->currentData().toString();
auto type = m_dataCombo->currentData(Qt::UserRole + 1).value<ParamType>(); auto type = m_dataCombo->currentData(Qt::UserRole + 1).value<ParamType>();
auto values = m_dataCombo->currentData(Qt::UserRole).toString().split(QLatin1Char(';'));
// we do not need all the options if there is only one keyframe
bool onlyOne = values.length() == 1;
m_previewLabel->setVisible(!onlyOne);
m_limitKeyframes->setVisible(!onlyOne);
m_limitNumber->setVisible(!onlyOne);
m_inPoint->setVisible(!onlyOne);
m_outPoint->setVisible(!onlyOne);
m_maximas = KeyframeModel::getRanges(comboData, m_model); m_maximas = KeyframeModel::getRanges(comboData, m_model);
m_sourceCombo->clear(); m_sourceCombo->clear();
if (type == ParamType::KeyframeParam) { if (type == ParamType::KeyframeParam) {
......
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