qdoc: Fix output filenames for QML basic type documentation

qdoc intends to prepend all html files related to QML with
a 'qml-' prefix. This doesn't work for basic QML types, as
those nodes do not have valid qml module name information.

This change fixes the issue by removing the requirement
for a qml module name, thereby always using the qml
prefix for a qml (basic) type.

Task-number: QTBUG-35229
Change-Id: If61572b2dc8a39be08140c37aa59646b88e99b29
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
bb10
Topi Reinio 2013-12-03 14:42:40 +01:00 committed by The Qt Project
parent ac54abfb07
commit dd97932a04
1 changed files with 8 additions and 8 deletions

View File

@ -334,14 +334,14 @@ QString Generator::fileBase(const Node *node) const
if (node->isQmlNode()) {
if (!node->qmlModuleName().isEmpty()) {
base.prepend(node->qmlModuleName() + QLatin1Char('-'));
/*
To avoid file name conflicts in the html directory,
we prepend a prefix (by default, "qml-") to the file name of QML
element doc files.
*/
if ((node->subType() == Node::QmlClass) || (node->subType() == Node::QmlBasicType)) {
base.prepend(outputPrefix(QLatin1String("QML")));
}
}
/*
To avoid file name conflicts in the html directory,
we prepend a prefix (by default, "qml-") to the file name of QML
element doc files.
*/
if ((node->subType() == Node::QmlClass) || (node->subType() == Node::QmlBasicType)) {
base.prepend(outputPrefix(QLatin1String("QML")));
}
}
else if (node->subType() == Node::QmlModule) {