KConfigDialog crash and fix for it
Joris Guisson
joris.guisson at gmail.com
Tue Oct 23 18:14:44 BST 2007
Version 2 of the patch, now with the signal in KPageDialog and KConfigDialog
responding to this.
On 10/22/07, Aaron J. Seigo <aseigo at kde.org> wrote:
>
> On Monday 22 October 2007, Joris Guisson wrote:
> > On 10/22/07, Aaron J. Seigo <aseigo at kde.org> wrote:
> > > On Monday 22 October 2007, Joris Guisson wrote:
> > > > Nobody interested ? I guess my patch must be fine then, shall I
> commit
> > > > ?
> > >
> > > having a second QMap seems ugly and a bit wasteful. can you do
> something
> > > like:
> > >
> > > QMap<QWidget *, KConfigDialogManager *>::iterator it =
> > > d->managerForPage.begin();
> > >
> > > while (it != d->managerForPage.end()) {
> > > if (it.value() == item->widget()) {
> > > delete it.value();
> > > d->managerForPage.erase(it);
> > > }
> > > ++it;
> > > }
> >
> > That was my first approach and it failed miserably, you see the widget
> you
> > give to KConfigDialog, gets stuffed into a KVBox.
>
> then i wonder if this would work:
>
> if (item->widget()->isAncestorOf(it.value())) {
>
> > Btw, didn't know binary compatibility was important at this point in
> time.
> > I can understand once 4.0 is out, but now ?
>
> well, we *are* trying to calm down and start respecting the API. tagging
> on
> wednesday and all.
True, but making one method virtual doesn't really change that much, and
wouldn't break compiling stuff which uses KPageDialog.
Anyway, the second version of the patch doesn't do this, so BC should not be
broken.
Joris,
--
> Aaron J. Seigo
> humru othro a kohnu se
> GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA EE75 D6B7 2EB1 A7F1 DB43
>
> KDE core developer sponsored by Trolltech
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20071023/94d22118/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kconfigdialog2.patch
Type: text/x-patch
Size: 4142 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20071023/94d22118/attachment.bin>
More information about the kde-core-devel
mailing list