-rw-r--r-- | kabc/addressee.cpp | 4 | ||||
-rw-r--r-- | kabc/addressee.h | 2 | ||||
-rw-r--r-- | kabc/field.cpp | 6 |
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 | |||
@@ -1996,6 +1996,10 @@ QString Addressee::resourceLabel() | |||
1996 | { | 1996 | { |
1997 | return i18n("Resource"); | 1997 | return i18n("Resource"); |
1998 | } | 1998 | } |
1999 | QString Addressee::categoryLabel() | ||
2000 | { | ||
2001 | return i18n("Category"); | ||
2002 | } | ||
1999 | 2003 | ||
2000 | void Addressee::setChanged( bool value ) | 2004 | void Addressee::setChanged( bool value ) |
2001 | { | 2005 | { |
diff --git a/kabc/addressee.h b/kabc/addressee.h index 2c81c1a..08d2f56 100644 --- a/kabc/addressee.h +++ b/kabc/addressee.h | |||
@@ -823,7 +823,7 @@ class Addressee | |||
823 | */ | 823 | */ |
824 | //US | 824 | //US |
825 | static QString resourceLabel(); | 825 | static QString resourceLabel(); |
826 | 826 | static QString categoryLabel(); | |
827 | /** | 827 | /** |
828 | Mark addressee as changed. | 828 | Mark addressee as changed. |
829 | */ | 829 | */ |
diff --git a/kabc/field.cpp b/kabc/field.cpp index d95cd19..89d0b77 100644 --- a/kabc/field.cpp +++ b/kabc/field.cpp | |||
@@ -57,6 +57,7 @@ class Field::FieldImpl | |||
57 | Suffix, | 57 | Suffix, |
58 | NickName, | 58 | NickName, |
59 | Birthday, | 59 | Birthday, |
60 | Category, | ||
60 | HomeAddressStreet, | 61 | HomeAddressStreet, |
61 | HomeAddressLocality, | 62 | HomeAddressLocality, |
62 | HomeAddressRegion, | 63 | HomeAddressRegion, |
@@ -195,6 +196,8 @@ QString Field::label() | |||
195 | return Addressee::urlLabel(); | 196 | return Addressee::urlLabel(); |
196 | case FieldImpl::Resource: | 197 | case FieldImpl::Resource: |
197 | return Addressee::resourceLabel(); | 198 | return Addressee::resourceLabel(); |
199 | case FieldImpl::Category: | ||
200 | return Addressee::categoryLabel(); | ||
198 | case FieldImpl::Sip: | 201 | case FieldImpl::Sip: |
199 | return Addressee::sipLabel(); | 202 | return Addressee::sipLabel(); |
200 | case FieldImpl::CustomField: | 203 | case FieldImpl::CustomField: |
@@ -277,6 +280,8 @@ QString Field::value( const KABC::Addressee &a ) | |||
277 | //US | 280 | //US |
278 | case FieldImpl::Resource: | 281 | case FieldImpl::Resource: |
279 | return a.resource()->resourceName(); | 282 | return a.resource()->resourceName(); |
283 | case FieldImpl::Category: | ||
284 | return a.categories().join(","); | ||
280 | case FieldImpl::HomePhone: | 285 | case FieldImpl::HomePhone: |
281 | return a.phoneNumber( PhoneNumber::Home ).number(); | 286 | return a.phoneNumber( PhoneNumber::Home ).number(); |
282 | case FieldImpl::BusinessPhone: | 287 | case FieldImpl::BusinessPhone: |
@@ -395,6 +400,7 @@ Field::List Field::allFields() | |||
395 | createField( FieldImpl::Suffix ); | 400 | createField( FieldImpl::Suffix ); |
396 | createField( FieldImpl::NickName, Personal ); | 401 | createField( FieldImpl::NickName, Personal ); |
397 | createField( FieldImpl::Birthday, Personal ); | 402 | createField( FieldImpl::Birthday, Personal ); |
403 | createField( FieldImpl::Category ); | ||
398 | createField( FieldImpl::HomeAddressStreet, Address|Personal ); | 404 | createField( FieldImpl::HomeAddressStreet, Address|Personal ); |
399 | createField( FieldImpl::HomeAddressLocality, Address|Personal ); | 405 | createField( FieldImpl::HomeAddressLocality, Address|Personal ); |
400 | createField( FieldImpl::HomeAddressRegion, Address|Personal ); | 406 | createField( FieldImpl::HomeAddressRegion, Address|Personal ); |