private slots
Simon Hausmann
hausmann at kde.org
Wed Jan 3 15:39:12 GMT 2007
On Wednesday 03 January 2007 16:23, Thomas Zander wrote:
> On Wednesday 03 January 2007 16:05, Simon Hausmann wrote:
> > This slot is not intended for applications to call/use and it is
> > connected to the internal widgets. There's no need to have it in the
> > public API and exported. You can use the following instead:
> >
> > ...
> > private:
> > Q_PRIVATE_SLOT(d, void slotDateChanged())
> >
> > KDateWidgetPrivate *d;
> > ...
>
> How is this better than the following?
>
> private slots:
> void slotDateChanged();
Because slotDateChanged() is a publically exported symbol. On non-Msvc
compilers you can still call it with #define private/public hacks. On Windows
you can't remove it at all without breaking binary compatibility (even if no
application calls it).
Simon
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20070103/a819c9d1/attachment.sig>
More information about the kde-core-devel
mailing list