forked from qt-creator/qt-creator
QmlDesigner: Properly resolve "dot properties" for dynamic objects
property NumberAnimation numberAnimation: NumberAnimation { } In this case this will expose the "dot properties" of numberAnimation. Change-Id: I40aafcc4f762ab6297c0829674ac62d92cbd713d Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
@@ -88,11 +88,17 @@ static TypeName resolveTypeName(const ASTPropertyReference *ref, const ContextPt
|
||||
if (ref->ast()->propertyToken.isValid()) {
|
||||
type = ref->ast()->memberType->name.toUtf8();
|
||||
|
||||
if (type == "alias") {
|
||||
const Value *value = context->lookupReference(ref);
|
||||
const Value *value = context->lookupReference(ref);
|
||||
|
||||
if (!value)
|
||||
return type;
|
||||
if (!value)
|
||||
return type;
|
||||
|
||||
if (const CppComponentValue * componentObjectValue = value->asCppComponentValue()) {
|
||||
type = componentObjectValue->className().toUtf8();
|
||||
dotProperties = getObjectTypes(componentObjectValue, context);
|
||||
}
|
||||
|
||||
if (type == "alias") {
|
||||
|
||||
if (const ASTObjectValue * astObjectValue = value->asAstObjectValue()) {
|
||||
if (astObjectValue->typeName()) {
|
||||
|
Reference in New Issue
Block a user