diff options
| author | Martin Smith <martin.smith@digia.com> | 2014-04-24 14:02:42 +0200 |
|---|---|---|
| committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-05-02 10:11:23 +0200 |
| commit | 761265ef64fed36dc3bb4b7cdc92904e19869466 (patch) | |
| tree | ceace8d1679306e43a790a77809c9c055ea1c532 /src/tools/qdoc/node.h | |
| parent | 0ccbe33a0453902264beefaaec22a0ec74cba678 (diff) | |
qdoc: attaching type of attached properties was missing
This bug was probably intoroduced when the QmlPropertyGroup
became a first class Node type. Otherwise, there is no way
to explain how it worked at all. But now qdoc includes the
attaching type.
Some debugging code was also cleaned up.
Task-number: QTBUG-35559
Change-Id: I478efb7f4356d51015af9f33c893958d4b4ae301
Reviewed-by: Topi Reiniƶ <topi.reinio@digia.com>
Diffstat (limited to 'src/tools/qdoc/node.h')
| -rw-r--r-- | src/tools/qdoc/node.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/tools/qdoc/node.h b/src/tools/qdoc/node.h index e0f6e5202d1..bbbc29d51a6 100644 --- a/src/tools/qdoc/node.h +++ b/src/tools/qdoc/node.h @@ -247,6 +247,7 @@ public: virtual Node* disambiguate(Type , SubType ) { return this; } virtual bool wasSeen() const { return false; } virtual void appendGroupName(const QString& ) { } + virtual QString element() const { return QString(); } bool isIndexNode() const { return indexNodeFlag_; } Type type() const { return nodeType_; } virtual SubType subType() const { return NoSubType; } @@ -658,7 +659,7 @@ public: virtual QString idNumber(); virtual bool isQmlPropertyGroup() const { return true; } - const QString& element() const { return parent()->name(); } + virtual QString element() const { return parent()->name(); } private: int idNumber_; @@ -697,8 +698,7 @@ public: virtual QString qmlModuleName() const { return parent()->qmlModuleName(); } virtual QString qmlModuleVersion() const { return parent()->qmlModuleVersion(); } virtual QString qmlModuleIdentifier() const { return parent()->qmlModuleIdentifier(); } - - const QString& element() const { return static_cast<QmlPropertyGroupNode*>(parent())->element(); } + virtual QString element() const; private: PropertyNode* findCorrespondingCppProperty(); @@ -858,7 +858,7 @@ public: QStringList reconstructParams(bool values = false) const; QString signature(bool values = false) const; - const QString& element() const { return parent()->name(); } + virtual QString element() const { return parent()->name(); } virtual bool isAttached() const { return attached_; } virtual bool isQmlNode() const { return ((type() == QmlSignal) || |
