Fix documentation of the new connect functions.
Make sure that qdoc can find the same function signature in the header than in the \fn tags in qobject.cpp Change-Id: Iccf2ba4e8f6384e9c3bfc878a446120f03e8a813 Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
This commit is contained in:
parent
ddf4faf33f
commit
8db8a34f07
@ -198,6 +198,10 @@ public:
|
|||||||
inline QMetaObject::Connection connect(const QObject *sender, const char *signal,
|
inline QMetaObject::Connection connect(const QObject *sender, const char *signal,
|
||||||
const char *member, Qt::ConnectionType type = Qt::AutoConnection) const;
|
const char *member, Qt::ConnectionType type = Qt::AutoConnection) const;
|
||||||
|
|
||||||
|
#ifdef Q_QDOC
|
||||||
|
QMetaObject::Connection QObject::connect(const QObject *sender, (T::*signal)(...), const QObject *receiver, (T::*method)(...), Qt::ConnectionType type)
|
||||||
|
QMetaObject::Connection QObject::connect(const QObject *sender, (T::*signal)(...), Functor functor)
|
||||||
|
#else
|
||||||
//Connect a signal to a pointer to qobject member function
|
//Connect a signal to a pointer to qobject member function
|
||||||
template <typename Func1, typename Func2>
|
template <typename Func1, typename Func2>
|
||||||
static inline QMetaObject::Connection connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal,
|
static inline QMetaObject::Connection connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal,
|
||||||
@ -261,6 +265,7 @@ public:
|
|||||||
new QFunctorSlotObject<Func2, SignalType::ArgumentCount, typename SignalType::Arguments, typename SignalType::ReturnType>(slot),
|
new QFunctorSlotObject<Func2, SignalType::ArgumentCount, typename SignalType::Arguments, typename SignalType::ReturnType>(slot),
|
||||||
Qt::DirectConnection, 0, &SignalType::Object::staticMetaObject);
|
Qt::DirectConnection, 0, &SignalType::Object::staticMetaObject);
|
||||||
}
|
}
|
||||||
|
#endif //Q_QDOC
|
||||||
|
|
||||||
static bool disconnect(const QObject *sender, const char *signal,
|
static bool disconnect(const QObject *sender, const char *signal,
|
||||||
const QObject *receiver, const char *member);
|
const QObject *receiver, const char *member);
|
||||||
@ -273,6 +278,9 @@ public:
|
|||||||
{ return disconnect(this, 0, receiver, member); }
|
{ return disconnect(this, 0, receiver, member); }
|
||||||
static bool disconnect(const QMetaObject::Connection &);
|
static bool disconnect(const QMetaObject::Connection &);
|
||||||
|
|
||||||
|
#ifdef Q_QDOC
|
||||||
|
bool QObject::disconnect(const QObject *sender, (T::*signal)(...), const Qbject *receiver, (T::*method)(...))
|
||||||
|
#else
|
||||||
template <typename Func1, typename Func2>
|
template <typename Func1, typename Func2>
|
||||||
static inline bool disconnect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal,
|
static inline bool disconnect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal,
|
||||||
const typename QtPrivate::FunctionPointer<Func2>::Object *receiver, Func2 slot)
|
const typename QtPrivate::FunctionPointer<Func2>::Object *receiver, Func2 slot)
|
||||||
@ -300,6 +308,7 @@ public:
|
|||||||
return disconnectImpl(sender, reinterpret_cast<void **>(&signal), receiver, zero,
|
return disconnectImpl(sender, reinterpret_cast<void **>(&signal), receiver, zero,
|
||||||
&SignalType::Object::staticMetaObject);
|
&SignalType::Object::staticMetaObject);
|
||||||
}
|
}
|
||||||
|
#endif //Q_QDOC
|
||||||
|
|
||||||
|
|
||||||
void dumpObjectTree();
|
void dumpObjectTree();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user