Line 1133 of thunar-vfs-volume-hal.c discards any volume that has a volume fsusage that isn't mountable. This makes thunar-vfs useless as a generic volume manager that can take action based on inserting a blank DVD or CD. I'm working on a volume manager that pops up a 'what do you want to do?' type dialog when a new device is inserted. One of the things I'd like it to be able to do is run some kind of GUI CD/DVD burning app when blank media is inserted. However, thunar-vfs never emits a volumes-added signal since the volume isn't counted at all. I'm not sure of the right way to make this work without breaking existing apps. Perhaps for these types of media, thunar_vfs_volume_is_present() should return false? (Actually, as an aside, I'm not sure how _STATUS_PRESENT could ever *not* be set for a ThunarVfsVolume using the hal backend. The condition for it being set is that it either is not a disc, or it has data. If _fsusage() reports that it's mountable, then it has to have data [right?]. So when a volume gets added, _STATUS_PRESENT should always be set, and the only way it would be unset is if you eject it, which, in the case of most volumes, would make the volume actually disappear and be removed from the volume list anyway.) Anyway, I'll look into working up a patch...
Created attachment 881 patch to allow blank/audio cds Ok, this should allow blank CDs to show up in the list. It also adds THUNAR_VFS_VOLUME_KIND_AUDIO_CD and detects those properly with HAL. Not sure how to do that with the FreeBSD backend.
Created attachment 882 better patch with device label New patch. Same as before, but sets the device name to "Audio CD". Adds a string, unfortunately :-P
Created attachment 883 even better patch, honest Ok, one last time. Be a little bit more strict about what's accepted. If _get_fsusage() says it's not mountable, and it's a disc, then make sure it either has audio, or is blank media. Without this, my Playstation CDs, while not mountable or usable, show up :-P. Also, add "Blank Media" for device_label if it's one of the blank media types. Bah, another new string.
thunar_vfs_volume_is_removable() should return TRUE for audio cds then. And I think CDs with both data and audio should still be handled as mountable data cds.
And the icon lookup must be extended for audio cds.
Created attachment 884 patch, take 4 Ok, includes stuff from comments #3 and #4.
(In reply to comment #6) > Created an attachment (id=884) [details] > patch, take 4 > > Ok, includes stuff from comments #3 and #4. Er, #4 and #5, of course.
Well, except for this part: "And I think CDs with both data and audio should still be handled as mountable data cds." Not sure what you mean here; can you elaborate? You can't actually mount an audio CD, or a data CD that doesn't have a recogniseable filesystem on it. Some virtual layer might be able to handle it (e.g., showing the audio CD as a series of tracks that can be saved as .wav), but that would be out of the scope of thunar-vfs, no?
I'm talking about mixed audio/data CDs, with both an ISO file system and audio tracks on it.
Ah, ok. Any idea how hal will categorise those? I don't have any handy to check with, but I'll try to make one tonight...
I guess it'll have both is_audio and is_data set.
Well, in that case, _get_fsusage() should return something reasonable, and it'll just behave as if it were a normal data CD, no?
Created attachment 891 patch, take 5 Ok, this guy will treat a disc with both data and audio as just a data disc. I'm not really sure if it's useful to try and handle it in any other way, unless we really want THUNAR_VFS_VOLUME_KIND_DATA_AND_AUDIO_CD. Do we?
Fixed with revision 24300. 2007-01-07 Benedikt Meurer <benny@xfce.org> * thunar-vfs/thunar-vfs-volume-hal.c, thunar-vfs/thunar-vfs-volume.{c,h}: Do not discard blank discs and pure audio discs. Bug #2599.