Re: [Rhythmbox-devel] Portable player support



On Wed, Jun 23, 2004 at 10:00:51AM +0100, Bastien Nocera wrote:
> On Tue, 2004-06-22 at 20:21 +0200, Christophe Fergeau wrote:
> > > May I humbly suggest looking into using HAL for doing the detection
> > > part instead of putting this in rhythmbox proper? HAL more or less
> > > keeps a list of the devices plugged in as well as data merged from
> > > device information files. Such as whether a device is a portable music
> > > player.
> > 
> > For the iPod, we need to know if an iPod is plugged, but more
> > importantly, it needs to be mounted, and rhythmbox needs to know where
> > it is mounted. Can HAL help for that ? ie is it possible to know things
> > like « there's an iPod plugged in, and its partitions are /dev/sda1
> > and /dev/sda2 » ? gnome-vfs can then be used to know if it's mounted and
> > where.
> 
> And HAL can be used to detect all this as well, gnome-volume-manager
> will mount the partitions it can. You don't have to do anything :)
> 

I might add that g-v-m may not be installed and automounting may be
disabled. To cover this you'll need to check block.is_mounted and if
it's FALSE you can just mount it yourself from Rhythmbox - which is
possible to do as an ordinary user because either 

 a) /etc/fstab have been updated by a HAL callout and the 'user' 
    option have been set; or

 b) (for those distros/OS'es who thinks messing around with the fstab
    is too dangerous) maybe mount(1) have been patched to allow this
    by using libhal for example

Cheers,
David

> ---
> Bastien Nocera <hadess hadess net> 
> The plan was simple, like my mate Trev. But unlike Trev, this plan just
> might work. 
> 
> _______________________________________________
> rhythmbox-devel mailing list
> rhythmbox-devel gnome org
> http://mail.gnome.org/mailman/listinfo/rhythmbox-devel


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]