From 6b9c4f7b45e07e93afadd50b4a0350ef901e8683 Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Sat, 13 Mar 2010 15:32:48 +0000 Subject: Allow to specify a group for a meta data item. The sorting of the meta data items is now done by the group. Within the group the sorting is done by their translated labels. svn path=/trunk/KDE/kdebase/apps/; revision=1102778 --- src/panels/information/kmetadatamodel.h | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'src/panels/information/kmetadatamodel.h') diff --git a/src/panels/information/kmetadatamodel.h b/src/panels/information/kmetadatamodel.h index 4b12563d3..ad8099dad 100644 --- a/src/panels/information/kmetadatamodel.h +++ b/src/panels/information/kmetadatamodel.h @@ -21,11 +21,10 @@ #include +#include #include -#include #include - #include #ifdef HAVE_NEPOMUK #define DISABLE_NEPOMUK_LEGACY @@ -64,6 +63,15 @@ public: void setItems(const KFileItemList& items); KFileItemList items() const; + /** + * @return Returns the name of the group the meta data indicated + * by \p metaDataUri belongs to. All meta data items are + * sorted by the group. Items within the group are sorted + * by their translated labels. The group name is not shown + * to the user interface and does not need to get translated. + */ + virtual QString group(const KUrl& metaDataUri) const; + #ifdef HAVE_NEPOMUK /** * @return Meta data for the items that have been set by @@ -71,7 +79,7 @@ public: * be invoked after the signal loadingFinished() has * been received (otherwise no data will be returned). */ - QMap data() const; + QHash data() const; protected: /** @@ -83,7 +91,7 @@ protected: * blocked if the operation takes longer. The default implementation * returns an empty list. */ - virtual QMap loadData() const; + virtual QHash loadData() const; #endif signals: -- cgit v1.3