[Kde-imaging] Selecting images for plugins

Aurélien Gâteau aurelien.gateau at free.fr
Mon Jun 28 15:14:47 CEST 2004


Le lundi 28 Juin 2004 14:37, Jesper K. Pedersen a écrit :
> | You mean something like this?
> |
> | class AlbumSelector {
> |   ...
> |   void setMultiSelection(bool);
> |   ...
> | }
> |
> | Then if the plugin calls setMultiSelection(false) then "auto-selecting"
> | won't happen? This is ok for me.
>
> Something like that yes, and then the check boxes was replaced with radio
> buttons.
>
> However, can you come up with an example where this would be needed? I mean
> to plugins it will in the end just be a set of images.

The web export plugin would be a good candidate: it wants only one 
ImageCollection to get the name and comment.

I think the selector could have the following API:

class AlbumSelector {
  void setMultiSelection(bool);

  // Returns the selected image collection.
  // Only valid if multi collection is off
  ImageCollection imageCollection() const;

  // Returns the images of all selected image collection.
  // An image won't appear twice in the returned list.
  KURL::List images() const;
}

What do you think about this?

Aurélien


More information about the Kde-imaging mailing list