[Kde-pim] solving right-click changing folder problem

Thomas McGuire mcguire at kde.org
Sun May 31 20:48:56 BST 2009


Hi,

On Sunday 31 May 2009 16:20:47 Frank Thieme wrote:
> On Sunday 31 May 2009 15:35:11 Ingo Klöcker wrote:
> > Just a warning: Most if not all of the code assumes that the folder the
> > action selected from the context menu should be performed on is the
> > current folder.
>
> Yeah I know, but most of them is easily rewritten to operate on a specific
> folder or on the folder the right-click was on. The only thing, as far as I
> see it, what could be a bit difficult is "empty".

Please separate all actions that work on folders out into a separate class and 
file, to make things cleaner. This really shouldn't be in kmmainwidget. Maybe 
"FolderActions"?
Some of the actions need to be asynchronous, as the "move all messages to 
trash" example you mentioned.
Please note that you need to open the folder in order to do anything to it. 
Currently, a folder is always open when selected, to display the messages in 
the message list. Opening a folder means reading the index file to get the 
list of messages in memory. When the action is complete, the folder needs to 
be closed again. These are the KMFolder::open() and close() methods.

Thanks for taking care of this. When this is implemented, it finally makes 
sense to have "Open in new tab" in the context menu, and get rid of the tab 
bar by default :)

Regards,
Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20090531/cc060dd0/attachment.sig>
-------------- next part --------------
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/


More information about the kde-pim mailing list