diff options
author | Martin Smith <msmith@trolltech.com> | 2010-02-22 14:24:17 (GMT) |
---|---|---|
committer | Martin Smith <msmith@trolltech.com> | 2010-02-22 14:24:17 (GMT) |
commit | d1b4e4666e4fe1a5fae0571c37535159c097f485 (patch) | |
tree | fca9a843f907e4bb01975b04ec45a831f771c95c | |
parent | 958ce5f41e3a9580ea0bdd99ca84dfdffbb85bf5 (diff) | |
download | Qt-d1b4e4666e4fe1a5fae0571c37535159c097f485.zip Qt-d1b4e4666e4fe1a5fae0571c37535159c097f485.tar.gz Qt-d1b4e4666e4fe1a5fae0571c37535159c097f485.tar.bz2 |
qdoc: List new QML elements in \sincelist for What's New page.
-rw-r--r-- | src/plugins/mediaservices/gstreamer/qgstreamermessage.cpp | 2 | ||||
-rw-r--r-- | tools/qdoc3/htmlgenerator.cpp | 28 | ||||
-rw-r--r-- | tools/qdoc3/htmlgenerator.h | 2 |
3 files changed, 29 insertions, 3 deletions
diff --git a/src/plugins/mediaservices/gstreamer/qgstreamermessage.cpp b/src/plugins/mediaservices/gstreamer/qgstreamermessage.cpp index 13a2454..0a689d9 100644 --- a/src/plugins/mediaservices/gstreamer/qgstreamermessage.cpp +++ b/src/plugins/mediaservices/gstreamer/qgstreamermessage.cpp @@ -48,7 +48,7 @@ static int wuchi = qRegisterMetaType<QGstreamerMessage>(); /*! - \class gstreamer::QGstreamerMessage + \class QGstreamerMessage \internal */ diff --git a/tools/qdoc3/htmlgenerator.cpp b/tools/qdoc3/htmlgenerator.cpp index c20f745..0477ebb 100644 --- a/tools/qdoc3/htmlgenerator.cpp +++ b/tools/qdoc3/htmlgenerator.cpp @@ -73,6 +73,7 @@ QString HtmlGenerator::sinceTitles[] = " New Typedefs", " New Properties", " New Variables", + " New QML Elements", " New Qml Properties", " New Qml Signals", " New Qml Methods", @@ -687,6 +688,8 @@ int HtmlGenerator::generateAtom(const Atom *atom, nsmap = newSinceMaps.find(atom->string()); NewClassMaps::const_iterator ncmap; ncmap = newClassMaps.find(atom->string()); + NewClassMaps::const_iterator nqcmap; + nqcmap = newQmlClassMaps.find(atom->string()); if ((nsmap != newSinceMaps.constEnd()) && !nsmap.value().isEmpty()) { QList<Section> sections; QList<Section>::ConstIterator s; @@ -697,6 +700,10 @@ int HtmlGenerator::generateAtom(const Atom *atom, while (n != nsmap.value().constEnd()) { const Node* node = n.value(); switch (node->type()) { + case Node::Fake: + if (node->subType() == Node::QmlClass) + sections[QmlClass].appendMember((Node*)node); + break; case Node::Namespace: sections[Namespace].appendMember((Node*)node); break; @@ -782,6 +789,8 @@ int HtmlGenerator::generateAtom(const Atom *atom, out() << "<h3>" << protectEnc((*s).name) << "</h3>\n"; if (idx == Class) generateCompactList(0, marker, ncmap.value(), QString("Q")); + else if (idx == QmlClass) + generateCompactList(0, marker, nqcmap.value(), QString("Q")); else if (idx == MemberFunction) { ParentMaps parentmaps; ParentMaps::iterator pmap; @@ -2332,7 +2341,11 @@ void HtmlGenerator::generateCompactList(const Node *relative, out() << "<a href=\"" << linkForNode(it.value(), relative) << "\">"; - QStringList pieces = fullName(it.value(), relative, marker).split("::"); + QStringList pieces; + if (it.value()->subType() == Node::QmlClass) + pieces << it.value()->name(); + else + pieces = fullName(it.value(), relative, marker).split("::"); out() << protectEnc(pieces.last()); out() << "</a>"; if (pieces.size() > 1) { @@ -3723,6 +3736,9 @@ void HtmlGenerator::findAllSince(const InnerNode *node) NewClassMaps::iterator ncmap = newClassMaps.find(sinceVersion); if (ncmap == newClassMaps.end()) ncmap = newClassMaps.insert(sinceVersion,NodeMap()); + NewClassMaps::iterator nqcmap = newQmlClassMaps.find(sinceVersion); + if (nqcmap == newQmlClassMaps.end()) + nqcmap = newQmlClassMaps.insert(sinceVersion,NodeMap()); if ((*child)->type() == Node::Function) { FunctionNode *func = static_cast<FunctionNode *>(*child); @@ -3742,6 +3758,15 @@ void HtmlGenerator::findAllSince(const InnerNode *node) nsmap.value().insert(className,(*child)); ncmap.value().insert(className,(*child)); } + else if ((*child)->subType() == Node::QmlClass) { + QString className = (*child)->name(); + if ((*child)->parent() && + (*child)->parent()->type() == Node::Namespace && + !(*child)->parent()->name().isEmpty()) + className = (*child)->parent()->name()+"::"+className; + nsmap.value().insert(className,(*child)); + nqcmap.value().insert(className,(*child)); + } } else { QString name = (*child)->name(); @@ -4319,7 +4344,6 @@ void HtmlGenerator::generateQmlInheritedBy(const QmlClassNode* cn, NodeList subs; QmlClassNode::subclasses(cn->name(),subs); if (!subs.isEmpty()) { - //subs.sort(); Text text; text << Atom::ParaLeft << "Inherited by "; appendSortedNames(text,cn,subs,marker); diff --git a/tools/qdoc3/htmlgenerator.h b/tools/qdoc3/htmlgenerator.h index 551bead..8fe0331 100644 --- a/tools/qdoc3/htmlgenerator.h +++ b/tools/qdoc3/htmlgenerator.h @@ -90,6 +90,7 @@ class HtmlGenerator : public PageGenerator Typedef, Property, Variable, + QmlClass, QmlProperty, QmlSignal, QmlMethod, @@ -326,6 +327,7 @@ class HtmlGenerator : public PageGenerator NewSinceMaps newSinceMaps; static QString sinceTitles[]; NewClassMaps newClassMaps; + NewClassMaps newQmlClassMaps; static int id; }; |