summaryrefslogtreecommitdiffstats
path: root/src/tools/qdoc/tree.cpp
diff options
context:
space:
mode:
authorMartin Smith <martin.smith@digia.com>2014-07-30 13:44:15 +0200
committerMartin Smith <martin.smith@digia.com>2014-08-22 18:23:39 +0200
commita5570bbf9af05fa33cfcc9f167786e8d2ca1e32e (patch)
tree40749767c38c88e6a52f66572664df5df61ab908 /src/tools/qdoc/tree.cpp
parent701b72c261922a2f96e3433f1f82646b1b339ff0 (diff)
qdoc: Remove all collision node stuff from qdoc
Now that the qdoc link command has ability to tell qdoc which module contains a link target or whether to link to a QML or CPP entity, collision pages should no longer be necessary. In fact, qdoc hasn't been generating any collisions for some time. This task removes all the collision node code from qdoc. Task-number: QTBUG-40506 Change-Id: I34d1980ca1c0fe4bb5ad27dd4b00e61fa7e6e335 Reviewed-by: Topi Reiniƶ <topi.reinio@digia.com>
Diffstat (limited to 'src/tools/qdoc/tree.cpp')
-rw-r--r--src/tools/qdoc/tree.cpp55
1 files changed, 2 insertions, 53 deletions
diff --git a/src/tools/qdoc/tree.cpp b/src/tools/qdoc/tree.cpp
index d43f82949a..07c7803a7c 100644
--- a/src/tools/qdoc/tree.cpp
+++ b/src/tools/qdoc/tree.cpp
@@ -194,47 +194,6 @@ QmlClassNode* Tree::findQmlTypeNode(const QStringList& path)
}
/*!
- First, search for a node with the specified \a name. If a matching
- node is found, if it is a collision node, another collision with
- this name has been found, so return the collision node. If the
- matching node is not a collision node, the first collision for this
- name has been found, so create a NameCollisionNode with the matching
- node as its first child, and return a pointer to the new
- NameCollisionNode. Otherwise return 0.
- */
-NameCollisionNode* Tree::checkForCollision(const QString& name)
-{
- Node* n = const_cast<Node*>(findNode(QStringList(name), 0, 0, Node::DontCare));
- if (n) {
- if (n->subType() == Node::Collision) {
- NameCollisionNode* ncn = static_cast<NameCollisionNode*>(n);
- return ncn;
- }
- if (n->isInnerNode())
- return new NameCollisionNode(static_cast<InnerNode*>(n));
- }
- return 0;
-}
-
-/*!
- This function is like checkForCollision() in that it searches
- for a collision node with the specified \a name. But it doesn't
- create anything. If it finds a match, it returns the pointer.
- Otherwise it returns 0.
- */
-NameCollisionNode* Tree::findCollisionNode(const QString& name) const
-{
- Node* n = const_cast<Node*>(findNode(QStringList(name), 0, 0, Node::DontCare));
- if (n) {
- if (n->subType() == Node::Collision) {
- NameCollisionNode* ncn = static_cast<NameCollisionNode*>(n);
- return ncn;
- }
- }
- return 0;
-}
-
-/*!
This function begins searching the tree at \a relative for
the \l {FunctionNode} {function node} identified by \a path.
The \a findFlags are used to restrict the search. If a node
@@ -252,15 +211,8 @@ const FunctionNode* Tree::findFunctionNode(const QStringList& path,
if (!qcn) {
QStringList p(path[1]);
Node* n = findNodeByNameAndType(p, Node::QmlType);
- if (n) {
- if (n->isQmlType())
- qcn = static_cast<QmlClassNode*>(n);
- else if (n->subType() == Node::Collision) {
- NameCollisionNode* ncn;
- ncn = static_cast<NameCollisionNode*>(n);
- qcn = static_cast<QmlClassNode*>(ncn->findAny(Node::QmlType, Node::NoSubType));
- }
- }
+ if (n && n->isQmlType())
+ qcn = static_cast<QmlClassNode*>(n);
}
if (qcn)
return static_cast<const FunctionNode*>(qcn->findFunctionNode(path[2]));
@@ -1018,9 +970,6 @@ void Tree::resolveTargets(InnerNode* root)
if (!alreadyThere)
docNodesByTitle_.insert(key, node);
}
- if (node->subType() == Node::Collision) {
- resolveTargets(node);
- }
}
if (child->doc().hasTableOfContents()) {