qdoc: Sort QML methods by name

qdoc was using the method signature (beginning
with the return type) to sort methods for listing
in the HTML output. Now qdoc sorts on the method
name, which makes the list easier to read.

Task-number: QTBUG-29708
Change-Id: If3785ccd5849df53b01043c2dada0b6bf3c00614
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
This commit is contained in:
Martin Smith 2013-03-14 09:07:58 +01:00 committed by The Qt Project
parent bc1fb206bb
commit 34598ddcbe

View File

@ -382,7 +382,7 @@ QString CodeMarker::sortName(const Node *node, const QString* name)
(node->type() == Node::QmlSignal) ||
(node->type() == Node::QmlSignalHandler)) {
const FunctionNode* func = static_cast<const FunctionNode *>(node);
return QLatin1Char('E') + func->signature();
return QLatin1Char('E') + func->name();
}
return QLatin1Char('B') + nodeName;
@ -438,8 +438,7 @@ void CodeMarker::insert(FastSection &fastSection,
if (!irrelevant) {
if (!inheritedMember || style == Subpage) {
QString key = sortName(node);
if (!fastSection.memberMap.contains(key))
fastSection.memberMap.insert(key, node);
fastSection.memberMap.insertMulti(key, node);
}
else {
if (node->parent()->type() == Node::Class) {