summaryrefslogtreecommitdiffstats
path: root/src/tools/qdoc/codemarker.cpp
diff options
context:
space:
mode:
authorMartin Smith <martin.smith@digia.com>2012-12-04 14:12:30 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-12-05 17:29:46 +0100
commitfd1f65a9b84d597078482cd420771620c406f8da (patch)
treeb6d35944932d4723094cb6bd989066cb127499ff /src/tools/qdoc/codemarker.cpp
parent4b819803f63ea58ac4cc4e8bc61f12321f91197a (diff)
qdoc: Don't include inherited members in the class ref
Once upon a time, the inherited functions, signals, slots, etc were not listed on the class reference page, but they were counted and a link to the base class was provided for them, eg: 2 public functions inherited from QAbstractListModel 39 public functions inherited from QAbstractItemModel 31 public functions inherited from QObject Somehow, this got broken, so that all these inherited things were listed on the class reference page as if they were members of the class. But they liunked to the documentation in the base class. This now works correctly again. It simnplifies the class reference pages a lot. Task-number: QTBUG-27496 Change-Id: If493da8cbf81634f1344b12094d9a06f8528e8e5 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/tools/qdoc/codemarker.cpp')
-rw-r--r--src/tools/qdoc/codemarker.cpp34
1 files changed, 17 insertions, 17 deletions
diff --git a/src/tools/qdoc/codemarker.cpp b/src/tools/qdoc/codemarker.cpp
index 7cc6b631f6..9fe91d93e8 100644
--- a/src/tools/qdoc/codemarker.cpp
+++ b/src/tools/qdoc/codemarker.cpp
@@ -396,7 +396,7 @@ void CodeMarker::insert(FastSection &fastSection,
bool irrelevant = false;
bool inheritedMember = false;
if (!node->relates()) {
- if (node->parent() != (const InnerNode*)fastSection.innerNode && !node->parent()->isAbstract()) {
+ if (node->parent() != fastSection.parent_) { // && !node->parent()->isAbstract()) {
if (node->type() != Node::QmlProperty) {
inheritedMember = true;
}
@@ -468,7 +468,7 @@ void CodeMarker::insert(FastSection& fastSection,
(parent->subType() == Node::QmlPropertyGroup)) {
parent = parent->parent();
}
- inheritedMember = (parent != (const InnerNode*)fastSection.innerNode);
+ inheritedMember = (parent != fastSection.parent_);
if (!inheritedMember || style == Subpage) {
QString key = sortName(node);
@@ -488,24 +488,24 @@ void CodeMarker::insert(FastSection& fastSection,
}
/*!
- Returns true if \a node represents a reimplemented member function.
- If it is, then it is inserted in the reimplemented member map in the
- section \a fs. And, the test is only performed if \a status is \e OK.
- Otherwise, false is returned.
+ Returns true if \a node represents a reimplemented member
+ function in the class of the FastSection \a fs. If it is
+ a reimplemented function, then it is inserted into the
+ reimplemented member map in \a fs. The test is performed
+ only if \a status is \e OK. True is returned if \a node
+ is inserted into the map. Otherwise, false is returned.
*/
bool CodeMarker::insertReimpFunc(FastSection& fs, Node* node, Status status)
{
- if (node->access() == Node::Private)
- return false;
-
- const FunctionNode* fn = static_cast<const FunctionNode*>(node);
- if ((fn->reimplementedFrom() != 0) && (status == Okay)) {
- bool inherited = (!fn->relates() && (fn->parent() != (const InnerNode*)fs.innerNode));
- if (!inherited) {
- QString key = sortName(fn);
- if (!fs.reimpMemberMap.contains(key)) {
- fs.reimpMemberMap.insert(key,node);
- return true;
+ if ((node->access() != Node::Private) && (node->relates() == 0)) {
+ const FunctionNode* fn = static_cast<const FunctionNode*>(node);
+ if ((fn->reimplementedFrom() != 0) && (status == Okay)) {
+ if (fn->parent() == fs.parent_) {
+ QString key = sortName(fn);
+ if (!fs.reimpMemberMap.contains(key)) {
+ fs.reimpMemberMap.insert(key,node);
+ return true;
+ }
}
}
}