[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: PATCH: Re: kdelibs/kdeui
From:       Ellis Whitehead <kde () ellisw ! net>
Date:       2002-01-30 14:23:51
[Download RAW message or body]

On Wednesday 30 January 2002 03:48, Simon Hausmann wrote:
> On Tue, Jan 29, 2002 at 09:38:27PM -0500, Ellis Whitehead wrote:
> > This patch has KAction::~KAction() call unplugAll() to remove itself from
> > any menu or toolbar it's in.
>
> I remember we had trouble with that, and Waldo also remembered that
> we had this in some 2.x version and had a lot of bug reports about
> this one. In addtion it doesn't work quite the way one would expect
> as calling that virtual method will only do half of the job by
> calling only KAction's own unplugAll(). (see previous threads on
> kde-core-devel about this problem)
>
> I think it's better to leave this out from the beta. Do you know any
> specific application where this was needed?

In the case that KFilePreview::setFileView( KFileView* ) is called a second 
time after the KDirOperator's popup menu has been shown.  Instead of relying 
on KAction destroyed() signals:
- KActionMenu could be modified to allow removal of items by index
- The "View" submenu could be constructed anew
	a) before display, or
	b) by connecting to the KActionCollection destroyed() signal
- We could say that KFilePreview::setFilewView() should only be called once.

As to whether any applications do this, Carsten said in a private thread:
> > In practice, does a KFilePreview object's setFileView(KFileView*) method
> > ever get called more than once?
>
> within kfile not, nor in kuickshow, but I can't tell about third-party
> apps...

Cheers,
Ellis
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic