[packagekit] Media Change Enums

Daniel Nicoletti dantti85-pk at yahoo.com.br
Wed Apr 1 08:36:11 PDT 2009


>Sounds like a good plan. Are you going to code up a patch for the daemon
>for this, or do you need a hand?

well i can try to code this, although i never changed the
daemon code, shoud i send i diff file to the ml,
or can i commit and you revert if it's not ok?

Daniel.



----- Mensagem original ----
De: Richard Hughes <hughsient at gmail.com>
Para: PackageKit users and developers list <packagekit at lists.freedesktop.org>
Enviadas: Quarta-feira, 1 de Abril de 2009 12:23:39
Assunto: Re: [packagekit] Media Change Enums

On Wed, 2009-04-01 at 08:15 -0700, Daniel Nicoletti wrote:
> Hi, as discussed with Richard here
> are the proposed enums and signals to handle
> media change in backends the use media as a repo.
> 
> PK_ERROR_ENUM_MEDIA_CHANGE_REQUIRED

Looks good to me.

> and the new signal:
> 
>     void        (* media_change_required)        (PkClient    *client,
>                                                                  const gchar    *media_id,
>                                                                  PkMediaTypeEnum type);

You want to have type, then id, to make it match the other signals.
Maybe future proof this and have:

type (CD), media_id (volume label), media_text (Extras Disk 4)

In this way we can do clever things in the UI comparing the media_id to
the volume label (using DeviceKit-disks) in the session if the wrong
disk is inserted.

> PkMediaTypeEnum {
>               GENERIC_DISK,
>               CD,
>               DVD
> }

Not GENERIC_DISK, you want to use UNKNOWN. You also need to prefix the
define with PK_MEDIA_TYPE_ENUM_

> for aptcc i just need generic disk sice afaik we can't know which kind is it,
> but i think cd + dvd should also be important.

Right, and others can be added as required.

> The user sees the dialog and inserts the media, pessing ok,
> the transaction will be rescheduled and if the user inserted the wrong media
> it will loop again and again.. till the user can put the right media,
> so the _("insert %s labeled: %s", media_type, media_id) dialog
> should have a cancel button so if the user want to disable this kind of media
> he can cancel and disable the cdrom repo in gpk-repo or kpk-settings.

Sounds like a good plan. Are you going to code up a patch for the daemon
for this, or do you need a hand?

Richard.


_______________________________________________
PackageKit mailing list
PackageKit at lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/packagekit



      Veja quais são os assuntos do momento no Yahoo! +Buscados
http://br.maisbuscados.yahoo.com



More information about the PackageKit mailing list