Programatically generated slot names
David Faure
faure at kde.org
Thu Jan 29 22:08:46 GMT 2009
On Thursday 29 January 2009, Richard Moore wrote:
> The SLOT macro actually tags a value to the end of the token iirc.
No, at the beginning ;)
qobjectdefs.h:#define SLOT(a) "1"#a
qobjectdefs.h:#define SIGNAL(a) "2"#a
This allows connect() to distinguish signal-to-slot connections
from signal-to-signal connections.
(and to barf on slot-to-signal connections like the one I found in plasma today :-)
--
David Faure, faure at kde.org, sponsored by Qt Software @ Nokia to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).
More information about the kde-core-devel
mailing list