4

Nautilus has options for what to do when media devices are added.

Media Handling Preferences

How does Nautilus know what applications to make available in these drop-down menus?

How do applications plug themselves in to this mechanism?

2 Answers 2

4

From http://library.gnome.org/admin/system-admin-guide/stable/mimetypes-registering.html.en:

Registering applications to handle MIME types is fairly straightforward. Applications are registered by creating a MimeType key in their .desktop entry file and listing each MIME type separated by a semicolon. The MimeType key should only be used in .desktop files whose Type key has the value Application. For more information on .desktop files, see Section 2.3 ― Desktop Entry Files.

Nautilus gets this infomation from the mimeinfo.cache files located in $XDG_DATA_DIRS/applications and $XDG_DATA_HOME/applications/ that are created by update-desktop-database.

0

As far as I understand it this is handled by the MIME, the same thing that handles what application opens which files. system (sorry I don't have the full details).

EDIT: DoR answered as I was typing. He nailed it.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .