From 338f9c4f7c42d2a7bcd2c5b37137b3cc7cd9775d Mon Sep 17 00:00:00 2001 From: Topi Reinio Date: Mon, 11 Aug 2014 11:58:44 +0200 Subject: qdoc: Distinguish between QML property and attached property A recent change in qtdeclarative (60ed6a43) added an attached property 'Window' to Item type, with property names identical to the ones already available in Window. This caused QDoc to report warnings for duplicate documentation for QML properties, because there was no distiction between a QML property and an attached property. This change fixes the issue by: - Allowing identical names for \qmlproperty and \qmlattachedproperty - Using distinct URLs/UUIDs/anchor references for them - Marking attached properties with '[attached]' qualifier in 'All Members' page. This doesn't solve the issue of disambiguating between a similarly named QML property and attached property when linking from an external location. However, these can be solved with the help of the \target command. Task-number: QTBUG-40674 Change-Id: Icc74de237366e9897334689fe354ab83e4af0356 Reviewed-by: Martin Smith Reviewed-by: Jerome Pasion Reviewed-by: Shawn Rutledge --- src/tools/qdoc/cppcodeparser.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/tools/qdoc/cppcodeparser.cpp') diff --git a/src/tools/qdoc/cppcodeparser.cpp b/src/tools/qdoc/cppcodeparser.cpp index 2755bf7254..df11ee5b24 100644 --- a/src/tools/qdoc/cppcodeparser.cpp +++ b/src/tools/qdoc/cppcodeparser.cpp @@ -832,7 +832,7 @@ void CppCodeParser::processQmlProperties(const Doc& doc, NodeList& nodes, DocLis if (splitQmlPropertyArg(arg, type, module, qmlType, property)) { qmlClass = qdb_->findQmlType(module, qmlType); if (qmlClass) { - if (qmlClass->hasQmlProperty(property) != 0) { + if (qmlClass->hasQmlProperty(property, attached) != 0) { QString msg = tr("QML property documented multiple times: '%1'").arg(arg); doc.startLocation().warning(msg); } -- cgit v1.2.3