Created attachment 3788 Patch Currently, thunar_g_volume_is_removable() returns true whenever g_volume_can_mount() returns true. This is not quite right, since g_volume_can_mount() returns true for some internal volumes (such as the Win7 partition on my dual-boot system). As a result, Thunar shows such volumes in the side pane with an "eject" icon next to them, which does not make sense. My patch removes the call to g_volume_can_mount().
I agree that it's probably not always a good idea to assume volumes with g_volume_can_mount() == true to be removable. But removing the g_volume_can_unmount() check looks wrong.
"killermoehre" on IRC suggests that "removable" be interpreted as "can be mounted"; in which case the current thunar_g_volume_is_removable() is okay. In that case, the problem remains that the "eject" icon is shown even when the volume is not mounted.
Yeah, that's how it is interpreted in order to show not only volumes that can be removed but also those that can be mounted (and possibly aren't yet). It might make sense to split that function up into thunar_g_volume_is_visible() (or something with a similar meaning) and thunar_g_volume_is_removable().
Created attachment 3789 Patch to hide "eject" icon when appropriate Here is a different solution: - Leave thunar_g_volume_is_removable() as it stands (though in my opinion it's badly named and should be called perhaps thunar_g_volume_is_handled() or thunar_g_volume_is_mountable()). - Don't show the eject button except for volumes that can be ejected (as reported by g_volume_can_eject()) or are mounted.
This patch does no longer apply, and I believe it has become obsolete. But to me it looks like this has been solved in some way or another.