Commit 823f7ff8 authored by Thomas Hartmann's avatar Thomas Hartmann Committed by Thomas Hartmann

QmlDesigner: Support Layout attached properties and expressions

Change-Id: I4518579364915a91e38c7748857d435a67fd00aa
Reviewed-by: default avatarTim Jenssen <tim.jenssen@theqtcompany.com>
parent 75de75b3
......@@ -63,6 +63,11 @@ using namespace QmlJS;
namespace {
static inline bool isSupportedAttachedProperties(const QString &propertyName)
{
return propertyName.startsWith(QLatin1String("Layout."));
}
static inline QStringList supportedVersionsList()
{
QStringList list;
......@@ -1294,7 +1299,8 @@ QmlDesigner::PropertyName TextToModelMerger::syncScriptBinding(ModelNode &modelN
} else { // Not an enum, so:
if (isPropertyChangesType(modelNode.type())
|| isConnectionsType(modelNode.type())
|| context->lookupProperty(prefix, script->qualifiedId)) {
|| context->lookupProperty(prefix, script->qualifiedId)
|| isSupportedAttachedProperties(astPropertyName)) {
AbstractProperty modelProperty = modelNode.property(astPropertyName.toUtf8());
syncExpressionProperty(modelProperty, astValue, TypeName(), differenceHandler); // TODO: parse type
return astPropertyName.toUtf8();
......
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