diff --git a/src/plugins/qmldesigner/components/propertyeditor/propertyeditor.cpp b/src/plugins/qmldesigner/components/propertyeditor/propertyeditor.cpp index cbe083fec09c39e2168db3ee00d0bbb5e88ba1d3..16f6a568d7d1a603fe4cefd5c305ab9d239438ae 100644 --- a/src/plugins/qmldesigner/components/propertyeditor/propertyeditor.cpp +++ b/src/plugins/qmldesigner/components/propertyeditor/propertyeditor.cpp @@ -381,8 +381,17 @@ void PropertyEditor::changeExpression(const QString &name) if (m_locked) return; + QString underscoreName(name); + underscoreName.replace(QLatin1Char('.'), QLatin1Char('_')); + QmlObjectNode fxObjectNode(m_selectedNode); - PropertyEditorValue *value = qobject_cast<PropertyEditorValue*>(QDeclarativeMetaType::toQObject(m_currentType->m_backendValuesPropertyMap.value(name))); + PropertyEditorValue *value = qobject_cast<PropertyEditorValue*>(QDeclarativeMetaType::toQObject(m_currentType->m_backendValuesPropertyMap.value(underscoreName))); + + if (!value) { + qWarning() << "PropertyEditor::changeExpression no value for " << underscoreName; + return; + } + try { if (fxObjectNode.currentState().isBaseState()) { fxObjectNode.modelNode().bindingProperty(name).setExpression(value->expression()); diff --git a/src/plugins/qmlprojectmanager/qmlprojectmanager.pro b/src/plugins/qmlprojectmanager/qmlprojectmanager.pro index d156db8c68b29800aeff7657c3bb2087aaaeac4c..3fca4d496c27e7ace933521ec134312a8fc91b8a 100644 --- a/src/plugins/qmlprojectmanager/qmlprojectmanager.pro +++ b/src/plugins/qmlprojectmanager/qmlprojectmanager.pro @@ -37,4 +37,5 @@ SOURCES += qmlproject.cpp \ qmlprojecttarget.cpp RESOURCES += qmlproject.qrc -OTHER_FILES += QmlProjectManager.pluginspec +OTHER_FILES += QmlProjectManager.pluginspec \ + QmlProject.mimetypes.xml