Skip to content
Commit 871cccc8 authored by David Faure's avatar David Faure
Browse files

Fix mimetype handling when a desktop file lists base and derived mimetype.

I had the following issue:
emacs.desktop says: MimeType=text/plain;text/x-csrc;
My mimeapps.list says: text/plain=kde4-kate.desktop;emacs.desktop;
   (and has no entry for text/x-csrc)

When opening a text/plain file, kate is selected, no problem.
But when opening a text/x-csrc file, emacs is selected, against my
expectations. Discussed on the XDG list, Alexander Larsson and I agreed
that when a desktop file lists both the base and derived mimetype, we
should simply ignore the derived mimetype, it's redundant.

The code is a bit complex, so let's test this in master before a possible
backport (if any; I couldn't find a bug report about this).
parent 13dd34d4
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment