From a942721edc9670fb9a66f952c23387c32de3c2f8 Mon Sep 17 00:00:00 2001 From: Martin Smith Date: Fri, 9 Dec 2016 10:19:40 +0100 Subject: doc: update dbus sources for clangqdoc Changed some uses of Q_QDOC to Q_CLANG_QDOC; eliminated some uses of Q_QDOC; correct some function signatures used for qdoc; added docs for swap() functions. Change-Id: I0d3c62d462bd3b10fd35d411bdfb93d952e6423d Reviewed-by: Martin Smith --- src/dbus/qdbuspendingreply.h | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) (limited to 'src/dbus/qdbuspendingreply.h') diff --git a/src/dbus/qdbuspendingreply.h b/src/dbus/qdbuspendingreply.h index da29894d15..4bf574e140 100644 --- a/src/dbus/qdbuspendingreply.h +++ b/src/dbus/qdbuspendingreply.h @@ -111,7 +111,7 @@ namespace QDBusPendingReplyTypes { template class QDBusPendingReply: -#ifdef Q_QDOC +#ifdef Q_CLANG_QDOC public QDBusPendingCall #else public QDBusPendingReplyData @@ -144,13 +144,21 @@ public: inline int count() const { return Count; } -#if defined(Q_QDOC) +#if defined(Q_CLANG_QDOC) QVariant argumentAt(int index) const; #else using QDBusPendingReplyData::argumentAt; #endif -#if defined(Q_QDOC) + template inline + const typename Select::Type argumentAt() const + { + Q_STATIC_ASSERT_X(Index >= 0 && Index < Count, "Index out of bounds"); + typedef typename Select::Type ResultType; + return qdbus_cast(argumentAt(Index), 0); + } + +#if defined(Q_CLANG_QDOC) bool isFinished() const; void waitForFinished(); @@ -159,18 +167,9 @@ public: QDBusError error() const; QDBusMessage reply() const; - template inline Type argumentAt() const; inline T1 value() const; inline operator T1() const; #else - template inline - const typename Select::Type argumentAt() const - { - Q_STATIC_ASSERT_X(Index >= 0 && Index < Count, "Index out of bounds"); - typedef typename Select::Type ResultType; - return qdbus_cast(argumentAt(Index), 0); - } - inline typename Select<0>::Type value() const { return argumentAt<0>(); -- cgit v1.2.3