[Xfce4-commits] r20356 - xfdesktop/trunk/src
Brian J. Tarricone
bjt23 at cornell.edu
Tue Mar 14 20:30:12 CET 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Benedikt Meurer wrote:
> Brian J. Tarricone wrote:
>
>>>>Author: kelnos
>>>>Date: 2006-03-12 12:59:19 +0000 (Sun, 12 Mar 2006)
>>>>New Revision: 20356
>>>>
>>>>Modified:
>>>> xfdesktop/trunk/src/xfce-desktop.c
>>>> xfdesktop/trunk/src/xfdesktop-file-icon-manager.c
>>>> xfdesktop/trunk/src/xfdesktop-file-icon-manager.h
>>>> xfdesktop/trunk/src/xfdesktop-file-icon.c
>>>> xfdesktop/trunk/src/xfdesktop-file-icon.h
>>>>Log:
>>>>* add support for showing removable media icons on the desktop (need to make
>>>>this disablable)
>>>
>>>You should test whether a medium is present for the volume, otherwise
>>>people on FreeBSD and Solaris (soon) will see media icons for CD-ROM/DVD
>>>drives even if no disc is present.
>>
>>So then how will it work? I'll get volumes-added when a CD is inserted,
>>and volumes-removed when the CD is ejected?
>
> That's how it works with HAL currently (there's no better way for the
> HAL backend right now, unfortunately). But with the other
> implementations, you'll get "volumes-added" for every entry in
> fstab/vfstab and then "changed" whenever the medium status changes (i.e.
> a CD is inserted or removed). Therefore, you should only display volumes
> for which thunar_vfs_volume_is_present() returns TRUE.
Ok, so does this make sense to you:
1. Do thunar_vfs_volume_manager_get_volumes(). Add each volume to the
desktop only if thunar_vfs_volume_is_present() is TRUE. If not, keep
the volume around and connect to its 'changed' signal.
2. On 'changed', check thunar_vfs_volume_is_present() and show the icon
if TRUE.
-brian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD4DBQFEFxnD6XyW6VEeAnsRAjrKAJ4zvHJhiixstPqAnBRH1ykRS7NBXgCY2Mfr
btDhzRjbqJlldBYxWWouhw==
=/gb+
-----END PGP SIGNATURE-----
More information about the Xfce4-dev
mailing list