summaryrefslogtreecommitdiffabout
path: root/kabc
Side-by-side diff
Diffstat (limited to 'kabc') (more/less context) (ignore whitespace changes)
-rw-r--r--kabc/addressee.cpp4
-rw-r--r--kabc/addressee.h2
-rw-r--r--kabc/field.cpp6
3 files changed, 11 insertions, 1 deletions
diff --git a/kabc/addressee.cpp b/kabc/addressee.cpp
index eec0f1f..3ce733d 100644
--- a/kabc/addressee.cpp
+++ b/kabc/addressee.cpp
@@ -1998,2 +1998,6 @@ QString Addressee::resourceLabel()
}
+QString Addressee::categoryLabel()
+{
+ return i18n("Category");
+}
diff --git a/kabc/addressee.h b/kabc/addressee.h
index 2c81c1a..08d2f56 100644
--- a/kabc/addressee.h
+++ b/kabc/addressee.h
@@ -825,3 +825,3 @@ class Addressee
static QString resourceLabel();
-
+ static QString categoryLabel();
/**
diff --git a/kabc/field.cpp b/kabc/field.cpp
index d95cd19..89d0b77 100644
--- a/kabc/field.cpp
+++ b/kabc/field.cpp
@@ -59,2 +59,3 @@ class Field::FieldImpl
Birthday,
+ Category,
HomeAddressStreet,
@@ -197,2 +198,4 @@ QString Field::label()
return Addressee::resourceLabel();
+ case FieldImpl::Category:
+ return Addressee::categoryLabel();
case FieldImpl::Sip:
@@ -279,2 +282,4 @@ QString Field::value( const KABC::Addressee &a )
return a.resource()->resourceName();
+ case FieldImpl::Category:
+ return a.categories().join(",");
case FieldImpl::HomePhone:
@@ -397,2 +402,3 @@ Field::List Field::allFields()
createField( FieldImpl::Birthday, Personal );
+ createField( FieldImpl::Category );
createField( FieldImpl::HomeAddressStreet, Address|Personal );