g_mount_get_icon() does not always return correct icon
Submitted by Kip
Link to original bug (#705166)
Description
I've consulted with the folks at xdg@lists.freedesktop.org and determined that apparently there is a way to provide a custom icon on mounted volumes in a fd.o friendly way. Mikkel on unity-devel informed me that most desktop environments are probably using glib's g_mount_get_icon() to retrieve this icon. However, I haven't really found a desktop environment that this works properly on so far. This may be because g_mount_get_icon() is used correctly, but not actually returning the correct icon when a custom one was provided.
Using a custom icon on a mounted volume can apparently be done in a fd.o friendly manner by providing a ".directory" file (note only an extension and no leading file name) in the root of the mounted volume. This is a standard Desktop Entry file with the Icon field set to some icon and probably with Type=Directory set.
If the problem is just with g_mount_get_icon(), then theoretically patching this GIO function should enable all desktop environments dependent on it to use the custom icon (e.g. Unity, Gnome, Xfce, etc.).