From kde-core-devel Wed Jan 03 15:39:12 2007 From: Simon Hausmann Date: Wed, 03 Jan 2007 15:39:12 +0000 To: kde-core-devel Subject: Re: private slots Message-Id: <200701031639.12700.hausmann () kde ! org> X-MARC-Message: https://marc.info/?l=kde-core-devel&m=116783876513642 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--nextPart1472984.Zd7UGntrXJ" --nextPart1472984.Zd7UGntrXJ Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline 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: > > =A0 =A0 Q_PRIVATE_SLOT(d, void slotDateChanged()) > > > > =A0 =A0 KDateWidgetPrivate *d; > > ... > > How is this better than the following? > > private slots: > =A0 void slotDateChanged(); Because slotDateChanged() is a publically exported symbol. On non-Msvc=20 compilers you can still call it with #define private/public hacks. On Windo= ws=20 you can't remove it at all without breaking binary compatibility (even if n= o=20 application calls it). Simon --nextPart1472984.Zd7UGntrXJ Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) iD4DBQBFm84gWXvMThJCpvIRAq8ZAJ9AYtVjTuwHIPpytBGvr3BslHOdegCTBcl5 Oqg5I197mfk3E0brGxIGog== =QiUT -----END PGP SIGNATURE----- --nextPart1472984.Zd7UGntrXJ--