EffectMaker: Block adding same effect node twice

The actual blocking is done at uniform level, as the problem of having
same effect node twice is duplicate uniforms.

Fixes: QDS-11470
Change-Id: I77b15b4a207efaebff39b4f6b1700d70262abcdb
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
This commit is contained in:
Miikka Heikkinen
2023-12-05 16:05:06 +02:00
parent 9184db8dfb
commit b5370c435e
8 changed files with 92 additions and 13 deletions

View File

@@ -76,6 +76,10 @@ EffectMakerWidget::EffectMakerWidget(EffectMakerView *view)
{"rootView", QVariant::fromValue(this)}});
QmlDesigner::QmlDesignerPlugin::trackWidgetFocusTime(
this, QmlDesigner::Constants::EVENT_NEWEFFECTMAKER_TIME);
connect(m_effectMakerModel.data(), &EffectMakerModel::nodesChanged, [this]() {
m_effectMakerNodesModel->updateCanBeAdded(m_effectMakerModel->uniformNames());
});
}