[KPhotoAlbum] display of the folder structure
Christoph Moseler
forums at moseler.net
Wed Aug 30 23:23:44 BST 2006
Hi Jesper,
currently for each folder in the folder-category the full path is
displayed. Maybe it's good idea to change the entries like that:
old:
aaa
+ aaa/bbb
+ aaa/bbb/ccc
new:
aaa
+ bbb
+ ccc
Cheers,
Christoph
Index: Browser/ContentFolder.cpp
===================================================================
--- Browser/ContentFolder.cpp (revision 579011)
+++ Browser/ContentFolder.cpp (working copy)
@@ -30,6 +30,7 @@
#include "DB/MemberMap.h"
#include "ExifFolder.h"
#include "Exif/Database.h"
+#include "qregexp.h"
#include <config.h>
#include "ContentFolderAction.h"
@@ -65,7 +66,14 @@
return i18n( "No other %1" ).arg( _category->text() );
}
else {
+ if ( _category->name() == QString::fromLatin1( "Folder" ) ) {
+ QRegExp rx( QString::fromLatin1( "(.*/)(.*)$") );
+ QString value = _value;
+ value.replace( rx, QString::fromLatin1("\\2") );
+ return value;
+ } else {
return _value;
+ }
}
}
More information about the Kphotoalbum
mailing list