[PATCH] Add the missing context menu to the folderview applet

Fredrik Höglund fredrik at kde.org
Mon Jun 9 00:14:01 CEST 2008


On Thursday 05 June 2008 22:55, Aaron J. Seigo wrote:
> On Thursday 05 June 2008, Fredrik Höglund wrote:
> > This patch adds an implemention of the context menu for the icons to the
> 
> awesome =)
> 
> > folderview applet, and also adds the familiar "Create New", "Undo", and
> > "Paste" actions to the applet's context menu.
> 
> cool; it's a bit unfortunate that the konq menu can't also be fetched as a set 
> of actions so plasma could merge it with the standard menu. oh well, not a 
> huge loss.

The Konq menu is also quite large, so I think it's actually preferable to
only have the standard menu entries when you right click empty space.

But it would actually be possible to do the reverse by adding actions
from the standard menu to the Konq menu.

> the only input i have is that it probably makes sense to delay initialization 
> of the KNewMenu and not call createAction() until that stuff is actually needed 
> (in showContextMenu, i imagine)

I'm not sure how expensive it is in practice, but I'll do that.

> it's also a bit unfortunate that you have to have your own action collection 
> there. there's already one in Applet and it's accessible by addAction and 
> action ..... we just don't provide direct access to the KActionCollection*, 
> which you need for the KonqPopupMenu ctor. hum...
> 
> i really do like how the implementation detail of having a KActionCollection 
> in Applet::Private is kept out of the public API, though ... perhaps if we run 
> into more such situations in applets we'll have to rethink that. for this 
> case, though, i don't think there's enough reason to adjust the Applet API 
> yet.

Yeah, exposing a pointer to the action collection seems like bad
API design.

Regards,
Fredrik



More information about the Panel-devel mailing list