File manager context menus
David Faure
faure at kde.org
Sun Aug 17 09:19:09 BST 2014
folderview seems to be using KonqPopupMenu,
while dolphin is using its own popup menu implementation.
This is the reason I started to factorize stuff out of KonqPopupMenu many
years ago, leading to KFileItemListProperties, KFileItemActions,
kabstractfileitemactionplugin.*, and other stuff now in kio, as well as
KonqCopyToMenu in libkonq --> so that dolphin and konqueror can share bits of
the context menu without sharing the toplevel context menu organization.
The big question is: what should folderview do?
Isn't it a bit weird that it uses the konqueror context menu rather than the
dolphin context menu, given that most users will only see folderview and
dolphin, and therefore will get an inconsistent experience? This being said,
dolphin's context menu isn't in a shared library :)
Konqueror's context menu is, but that's the source of the dependency issue in
the frameworks world, workspace not being able to depend on apps.
I think I can imagine three solutions out of this:
1) folderview assembles its own popupmenu implementation out of the individual
bits offered by KIO (and I keep moving the necessary bits there). Solves the
dependency issue, but leads to even more inconsistency.
2) KonqPopupMenu moves to KIO -- but then this begs the question, should
dolphin use it (I guess so), and should even KFileDialog use it (I guess not).
3) A popupmenu implementation moves to KIO, made of the best stuff from
dolphin and konqueror.
Comparing the context menu in dolphin and konqueror, it seems to me that
* 95% of it is the same, just possibly in a different order
* Dolphin has a "Add To Places" action (for directories)
* Konqueror has a "Preview In..." action
Makes sense - different integration with the rest of the app.
But we could just provide a way for the app to insert its own actions, while
sharing all the rest of the code.
Dolphin developers, Folderview developers, what do you think?
--
David Faure, faure at kde.org, http://www.davidfaure.fr
Working on KDE Frameworks 5
More information about the kfm-devel
mailing list