summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorMartin Smith <msmith@trolltech.com>2009-10-29 13:50:51 (GMT)
committerMartin Smith <msmith@trolltech.com>2009-10-29 13:50:51 (GMT)
commit5e4035ede6505f638f4741dcebbf19e485a1b993 (patch)
tree2ae87d72334b0b0168e22cbf141a40185a027d4c /tools
parent8bbf1907613d88e38630ec0343bb9f0d1fb6c5d0 (diff)
downloadQt-5e4035ede6505f638f4741dcebbf19e485a1b993.zip
Qt-5e4035ede6505f638f4741dcebbf19e485a1b993.tar.gz
Qt-5e4035ede6505f638f4741dcebbf19e485a1b993.tar.bz2
qdoc3: Fixed a linking error for qml properties.
This: https://qtmetrics.europe.nokia.com/kinetic-declarativeui/qml-item.html#rotation-prop should now be this: https://qtmetrics.europe.nokia.com/kinetic-declarativeui/qml-item.html#transformOrigin-prop)
Diffstat (limited to 'tools')
-rw-r--r--tools/qdoc3/htmlgenerator.cpp11
-rw-r--r--tools/qdoc3/pagegenerator.cpp19
2 files changed, 14 insertions, 16 deletions
diff --git a/tools/qdoc3/htmlgenerator.cpp b/tools/qdoc3/htmlgenerator.cpp
index 18c7916..eaf4b2e 100644
--- a/tools/qdoc3/htmlgenerator.cpp
+++ b/tools/qdoc3/htmlgenerator.cpp
@@ -3467,10 +3467,13 @@ QString HtmlGenerator::refForNode(const Node *node)
ref += "-" + QString::number(func->overloadNumber());
}
break;
- case Node::Property:
-#ifdef QDOC_QML
+#ifdef QDOC_QML
+ case Node::Fake:
+ if (node->subType() != Node::QmlPropertyGroup)
+ break;
case Node::QmlProperty:
#endif
+ case Node::Property:
ref = node->name() + "-prop";
break;
#ifdef QDOC_QML
@@ -3512,9 +3515,9 @@ QString HtmlGenerator::linkForNode(const Node *node, const Node *relative)
// ### reintroduce this test, without breaking .dcf files
if (fn != outFileName())
#endif
- link += fn;
+ link += fn;
- if (!node->isInnerNode()) {
+ if (!node->isInnerNode() || node->subType() == Node::QmlPropertyGroup) {
ref = refForNode(node);
if (relative && fn == fileName(relative) && ref == refForNode(relative))
return QString();
diff --git a/tools/qdoc3/pagegenerator.cpp b/tools/qdoc3/pagegenerator.cpp
index 83ea561..7d9fbee 100644
--- a/tools/qdoc3/pagegenerator.cpp
+++ b/tools/qdoc3/pagegenerator.cpp
@@ -81,14 +81,13 @@ QString PageGenerator::fileBase(const Node *node)
{
if (node->relates())
node = node->relates();
- else if (!node->isInnerNode()) {
+ else if (!node->isInnerNode())
node = node->parent();
#ifdef QDOC_QML
- if (node->subType() == Node::QmlPropertyGroup) {
- node = node->parent();
- }
-#endif
+ if (node->subType() == Node::QmlPropertyGroup) {
+ node = node->parent();
}
+#endif
QString base = node->doc().baseName();
if (!base.isEmpty())
@@ -97,6 +96,7 @@ QString PageGenerator::fileBase(const Node *node)
const Node *p = node;
forever {
+ const Node *pp = p->parent();
base.prepend(p->name());
#ifdef QDOC_QML
/*
@@ -104,15 +104,10 @@ QString PageGenerator::fileBase(const Node *node)
we prepend "qml-" to the file name of QML element doc
files.
*/
- if ((p->subType() == Node::QmlClass) ||
- (p->subType() == Node::QmlPropertyGroup))
- base.prepend("qml-");
- else if ((p->type() == Node::QmlProperty) ||
- (p->type() == Node::QmlSignal) ||
- (p->type() == Node::QmlMethod))
+ if (p->subType() == Node::QmlClass) {
base.prepend("qml-");
+ }
#endif
- const Node *pp = p->parent();
if (!pp || pp->name().isEmpty() || pp->type() == Node::Fake)
break;
base.prepend(QLatin1Char('-'));