[Panel-devel] kalming kickoff

Aaron J. Seigo aseigo at kde.org
Mon Nov 12 19:53:20 CET 2007


On Monday 12 November 2007, Kevin Ottens wrote:
> Le lundi 12 novembre 2007, Aaron J. Seigo a écrit :
> > if the device isn't currently accessible, e.g. it's an unmounted
> > CD/DVD/etc, i'd like to say what kind of device it is since it will have
> > neither a sensible path nor a sensible title.
>
> I don't get it... Are we talking about the drive, or the volume in the
> drive? (one being the parent of the other)

depends on the state of the volume. if it is a hotpluggable/removable device 
that is not currently accessible, i'm interested in the drive. otherwise i 
was the volume info.

> > this information seems to be
> > in StorageDrive::DriveType? is there a way to get a translated string out
> > for a given DriveType (i couldn't find such a thing)?
>
> Nope.

darn. hm. would it make sense to offer such a thing? =) i can add it to 
Kickoff for now, but maybe you could move it to Solid later, e.g. 4.1?

> > and is it possible to
> > get a StorageDrive oject for a non-mounted drive?
>
> Of course, the StorageDrive (only exception being the floppy drives) hold
> no "mounting" information anyway.

i don't want mount information. in the case that there is an unmounted DVD 
drive, i don't want to show "THE_BOTHERSOME_MAN" (which is what my menu 
currently says is in the drive ;) or "/media/cdrom0" (because it isn't 
there). instead, i'd like to just say "DVD drive" on top, perhaps with the 
eventually mountpoint ("/media/cdrom0") below it in the subtext.

so my question is how to find out what kind of device it is so i can 
output "DVD drive" in user-friendly terms.

tangentially: right now kickoff attempts to setup (!) all drives it lists. 
that was hidden amongst Robert's recent commits and that seems rather 
unfriendly to the system. i'd like to move the setup attempt to selection, so 
that the drive remains un-setup until the user clicks on it ...

> > (i'm having issues with device.as<Solid::StorageDrive> in general... it
> > returning a null ptr in all cases ... )
>
> Odd... But I think you misunderstood what I said earlier, in the tree when
> a device has the StorageVolume interface then the parent of this device has
> the StorageDrive interface. I think you try to get StorageDrive and
> StorageVolume on the same device.

> > i also notice that we don't seem to be responding to hotplug events in
> > kickoff. i'll have to fix that today as well.
>
> One could say you really want to use KFilePlacesModel instead of all this
> code that leads to feature duplication. :-)

indeed. i don't think it would be wise at this point, however, due to some 
layout needs of kickoff that would require a bunch of work. for 4.1 though 
let's take a look at doing this.

> IIRC someone made a places dataengine...

kickoff isn't using dataengines but full models.

-- 
Aaron J. Seigo
humru othro a kohnu se
GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA  EE75 D6B7 2EB1 A7F1 DB43

KDE core developer sponsored by Trolltech
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/panel-devel/attachments/20071112/4fa784ae/attachment-0001.pgp 


More information about the Panel-devel mailing list