From 1381b25560127fa08c91f6d8ff99ed104a907b82 Mon Sep 17 00:00:00 2001 From: Martin Smith Date: Wed, 17 Feb 2016 14:41:47 +0100 Subject: qdoc: QML basic types can now have methods MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit \qmlmethod now works for QML basic types. Use it the same way it is used for QML types. \qmlsignal should work now too, but I only tested this for methods. There is now not much difference between QML types and basic types. Change-Id: Ie7dfb01dd2ff0b68944b864ebe29d4a95ba7d550 Task-number: QTBUG-51125 Reviewed-by: Topi Reiniƶ --- src/qdoc/cppcodemarker.cpp | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) (limited to 'src/qdoc/cppcodemarker.cpp') diff --git a/src/qdoc/cppcodemarker.cpp b/src/qdoc/cppcodemarker.cpp index 0f413c7f5..23ac9df93 100644 --- a/src/qdoc/cppcodemarker.cpp +++ b/src/qdoc/cppcodemarker.cpp @@ -1108,50 +1108,50 @@ QString CppCodeMarker::addMarkUp(const QString &in, /*! This function is for documenting QML properties. It returns the list of documentation sections for the children of the - \a qmlTypeNode. + \a aggregate. */ -QList
CppCodeMarker::qmlSections(QmlTypeNode* qmlTypeNode, SynopsisStyle style, Status status) +QList
CppCodeMarker::qmlSections(Aggregate* aggregate, SynopsisStyle style, Status status) { QList
sections; - if (qmlTypeNode) { + if (aggregate) { if (style == Summary) { - FastSection qmlproperties(qmlTypeNode, + FastSection qmlproperties(aggregate, "Properties", QString(), "property", "properties"); - FastSection qmlattachedproperties(qmlTypeNode, + FastSection qmlattachedproperties(aggregate, "Attached Properties", QString(), "attached property", "attached properties"); - FastSection qmlsignals(qmlTypeNode, + FastSection qmlsignals(aggregate, "Signals", QString(), "signal", "signals"); - FastSection qmlsignalhandlers(qmlTypeNode, + FastSection qmlsignalhandlers(aggregate, "Signal Handlers", QString(), "signal handler", "signal handlers"); - FastSection qmlattachedsignals(qmlTypeNode, + FastSection qmlattachedsignals(aggregate, "Attached Signals", QString(), "attached signal", "attached signals"); - FastSection qmlmethods(qmlTypeNode, + FastSection qmlmethods(aggregate, "Methods", QString(), "method", "methods"); - FastSection qmlattachedmethods(qmlTypeNode, + FastSection qmlattachedmethods(aggregate, "Attached Methods", QString(), "attached method", "attached methods"); - QmlTypeNode* qcn = qmlTypeNode; + Aggregate* qcn = aggregate; while (qcn != 0) { NodeList::ConstIterator c = qcn->childNodes().constBegin(); while (c != qcn->childNodes().constEnd()) { @@ -1206,17 +1206,17 @@ QList
CppCodeMarker::qmlSections(QmlTypeNode* qmlTypeNode, SynopsisStyl append(sections,qmlattachedmethods); } else if (style == Detailed) { - FastSection qmlproperties(qmlTypeNode, "Property Documentation","qmlprop","member","members"); - FastSection qmlattachedproperties(qmlTypeNode,"Attached Property Documentation","qmlattprop", + FastSection qmlproperties(aggregate, "Property Documentation","qmlprop","member","members"); + FastSection qmlattachedproperties(aggregate,"Attached Property Documentation","qmlattprop", "member","members"); - FastSection qmlsignals(qmlTypeNode,"Signal Documentation","qmlsig","signal","signals"); - FastSection qmlsignalhandlers(qmlTypeNode,"Signal Handler Documentation","qmlsighan","signal handler","signal handlers"); - FastSection qmlattachedsignals(qmlTypeNode,"Attached Signal Documentation","qmlattsig", + FastSection qmlsignals(aggregate,"Signal Documentation","qmlsig","signal","signals"); + FastSection qmlsignalhandlers(aggregate,"Signal Handler Documentation","qmlsighan","signal handler","signal handlers"); + FastSection qmlattachedsignals(aggregate,"Attached Signal Documentation","qmlattsig", "signal","signals"); - FastSection qmlmethods(qmlTypeNode,"Method Documentation","qmlmeth","member","members"); - FastSection qmlattachedmethods(qmlTypeNode,"Attached Method Documentation","qmlattmeth", + FastSection qmlmethods(aggregate,"Method Documentation","qmlmeth","member","members"); + FastSection qmlattachedmethods(aggregate,"Attached Method Documentation","qmlattmeth", "member","members"); - QmlTypeNode* qcn = qmlTypeNode; + Aggregate* qcn = aggregate; while (qcn != 0) { NodeList::ConstIterator c = qcn->childNodes().constBegin(); while (c != qcn->childNodes().constEnd()) { @@ -1275,8 +1275,8 @@ QList
CppCodeMarker::qmlSections(QmlTypeNode* qmlTypeNode, SynopsisStyl members is prepared. */ ClassMap* classMap = 0; - FastSection all(qmlTypeNode,QString(),QString(),"member","members"); - QmlTypeNode* current = qmlTypeNode; + FastSection all(aggregate,QString(),QString(),"member","members"); + Aggregate* current = aggregate; while (current != 0) { /* If the QML type is abstract, do not create @@ -1291,7 +1291,7 @@ QList
CppCodeMarker::qmlSections(QmlTypeNode* qmlTypeNode, SynopsisStyl */ if (!current->isAbstract() || !classMap) { classMap = new ClassMap; - classMap->first = current; + classMap->first = static_cast(current); all.classMapList_.append(classMap); } NodeList::ConstIterator c = current->childNodes().constBegin(); -- cgit v1.2.1