qt5base-lts/tests/auto/corelib/kernel/qobject
Dario Freddi 76b06f993e QObject: allow connecting to functors with a receiver object
Up to now, it was only possible to connect to functors in a direct
way, without being capable of using Qt::ConnectionType. This patch
allows for specifying a receiver for Functors and function
pointers, hence making it possible to specify effectively the
connection type.

To do this properly, it was needed to add an enum in FunctionPointer
representing whether the considered function is a member function
or not, to reduce ambiguity upon overloaded calls.

Moreover, now senders are checked for the existence of a slot obj
as well. This way, should the context be freed, the slot obj and
the functor contained in it will be freed as well.

On a side note, connecting to a static slot
(like QCoreApplication::quit) specifying the receiver object is
now compiling.

Change-Id: I46474099413b1dc6ca4db9934191d469baeef070
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2013-09-16 23:46:30 +02:00
..
signalbug tests: Make the QT assignments more explicit 2013-08-21 19:05:52 +02:00
test Set the Qt API level to compatibility mode in all tests. 2012-08-01 15:37:46 +02:00
.gitignore QObject-test: Reorganize subprocess. 2011-12-14 07:07:09 +01:00
qobject.pro Fixed tst_qobject signalbug silently not compiled in -fast builds. 2012-02-23 09:06:44 +01:00
tst_qobject.cpp QObject: allow connecting to functors with a receiver object 2013-09-16 23:46:30 +02:00