[KPhotoAlbum] Very experimental image-grouping patch

Paul Fleischer paul at xpg.dk
Thu Nov 29 00:11:12 CET 2007


2007/11/28, Tero Tilus <tero at tilus.net>:
[snip]
> images = loadImagesFromXML();
> parent_cache = new imageList();
> foreach img in images {
>   if( images->parent() != null ) {
>     if ( ! parent = parent_cache->get(img->parent()) ) {
>       parent = DB::ImageDB::instance()->info( img->parent() );
>       parent_cache->add(parent);
>     }
>     parent->addChildImage(img->fileName());
>   }
> }

I might be wrong here, but doesn't ImageDB::info() do exactly this?

/Paul


More information about the KPhotoAlbum mailing list