diff --git a/src/plugins/effectcomposer/effectcomposercontextobject.cpp b/src/plugins/effectcomposer/effectcomposercontextobject.cpp index 95ebe7a3670..68053055b30 100644 --- a/src/plugins/effectcomposer/effectcomposercontextobject.cpp +++ b/src/plugins/effectcomposer/effectcomposercontextobject.cpp @@ -168,11 +168,11 @@ int EffectComposerContextObject::devicePixelRatio() QStringList EffectComposerContextObject::allStatesForId(const QString &id) { - if (m_model && m_model->rewriterView()) { - const QmlDesigner::QmlObjectNode node = m_model->rewriterView()->modelNodeForId(id); - if (node.isValid()) - return node.allStateNames(); - } + if (m_model) { + const QmlDesigner::QmlObjectNode node = m_model->modelNodeForId(id); + if (node.isValid()) + return node.allStateNames(); + } return {}; }