[Kde-imaging] Selecting images for plugins

Jesper K. Pedersen blackie at blackie.dk
Tue Jun 29 09:55:28 CEST 2004


On Tuesday 29 June 2004 09:48, Aurélien Gâteau wrote:
| Le lundi 28 Juin 2004 17:51, Renchi Raju a écrit :
| > On Mon, 28 Jun 2004, Aurélien Gâteau wrote:
| > > Le lundi 28 Juin 2004 15:26, Jesper K. Pedersen a écrit :
| > >
| > > e the following API:
| > > > |   // Returns the images of all selected image collection.
| > > > |   // An image won't appear twice in the returned list.
| > > > |   KURL::List images() const;
| > > >
| > > > images() is not needed is it? that is returned from ImageCollection.
| > >
| > > It is for plugins which don't care about albums, but only want a set of
| > > images, like CD archiving plugin.
| >
| > you mean all the images are returned as one list? i don't see how its
| > useful, as the cdarchiving plugin (if it uses this list) will have to put
| > all the images in one folder on the cd.
|
| After thinking about it, I think a better place would be as a static method
| in ImageCollection:
| class ImageCollection {
|   ...
|   static KURL::List join(QValueList<ImageCollection>);
|   ...
| }
|
| But it's just a helper function. If you don't think it's useful, let's
| forget it.
|
| > > Yes. A better API would be:
| > >
| > > class AlbumSelector : public QWidget {
| > >   bool multiSelection() const;
| > >   void setMultiSelection(bool);
| > >
| > >   // Returns a list of all selected image collections.
| > >   // If multiSelection is off, the list will only contain one item
| > >   QValueList<ImageCollection> selectedImageCollections() const;
| > >
| > >   // Returns the images of all selected image collections.
| > >   // An image won't appear twice in the returned list.
| > >   KURL::List images() const;
| > > }
| >
| > imo the multiselection option is not very useful. if an album doesn't
| > want multiple albums, there is no point providing a selector to choose
| > albums.
|
| Well, looking at the current plugins, it seems only the import plugins
| would need single selection, but that's TODO point #2. Let me start another
| thread for it :-). For now, I agree we can forget this multiSelection
| option. This means the "API" is reduced to:
|
| class AlbumSelector : public QWidget {
|   QValueList<ImageCollection> selectedImageCollections() const;
| }
|
| Quite minimalistic :-)
|
| Is it ok for everyone if I update the TODO to what we concluded?
OK with me


More information about the Kde-imaging mailing list