Review Request 120015: KIO: Save the default application into the group [Default Applications]

Luc Menut lmenut at
Sun Aug 31 10:07:02 UTC 2014

This is an automatically generated e-mail. To reply, visit:

Review request for KDE Frameworks and David Faure.

Repository: kio


Similar change for KIO as Review Request #120012
Save the default application for a given mimetype by writing into the group [Default Applications] in the file mimeapps.list, according to mime-apps-spec 1.0 .

Currently, the default application saved by KDE (first application in [Added Assocations] ) is not respected by applications using glib/gio (which follow mime-apps-spec 1.0) if there is a default application at a lower level (eg $XDG_DATA_DIRS/applications/mimeapps.list), because the most-preferred .desktop from [Added Assocations] for a given mimetype is used to determine the default application only if there is no entry in [Default Applications] for this mimetype at all levels.
mime-apps-spec 1.0#default
"... In the absence of such an entry, the next mimeapps.list is checked. Once all levels have been checked, if no entry could be found, the implementations should pick the most-preferred .desktop files associated with the mimetype, taking into account added and removed associations as per the next section."

eg. if we have
- ~/.local/share/applications/mimeapps.list (with no group [Default Applications] )
[Added Assocations]

- /usr/share/applications/mimeapps.list (from distrib preferences)
[Default Applications]

according to mime-apps-spec 1.0, the default application used for mimetype1 will be foo3.desktop instead of foo1.desktop expected by a KDE user.

The proposed patch fixes this.

Luc Menut - Mageia

PS: I don't have write access to kde git, so could you commit the change if the patch looks fine. Thanks.


  src/widgets/kopenwithdialog.cpp 4c56fc1 



tested with kio 5.1.0 (Mageia Cauldron)


Luc Menut

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Kde-frameworks-devel mailing list