-rw-r--r-- | kabc/field.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kabc/field.h b/kabc/field.h index 9e06597..55cc705 100644 --- a/kabc/field.h +++ b/kabc/field.h | |||
@@ -1,110 +1,110 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of libkabc. | 2 | This file is part of libkabc. |
3 | Copyright (c) 2002 Cornelius Schumacher <schumacher@kde.org> | 3 | Copyright (c) 2002 Cornelius Schumacher <schumacher@kde.org> |
4 | 4 | ||
5 | This library is free software; you can redistribute it and/or | 5 | This library is free software; you can redistribute it and/or |
6 | modify it under the terms of the GNU Library General Public | 6 | modify it under the terms of the GNU Library General Public |
7 | License as published by the Free Software Foundation; either | 7 | License as published by the Free Software Foundation; either |
8 | version 2 of the License, or (at your option) any later version. | 8 | version 2 of the License, or (at your option) any later version. |
9 | 9 | ||
10 | This library is distributed in the hope that it will be useful, | 10 | This library is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
13 | Library General Public License for more details. | 13 | Library General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU Library General Public License | 15 | You should have received a copy of the GNU Library General Public License |
16 | along with this library; see the file COPYING.LIB. If not, write to | 16 | along with this library; see the file COPYING.LIB. If not, write to |
17 | the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 17 | the Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
18 | Boston, MA 02111-1307, USA. | 18 | Boston, MA 02111-1307, USA. |
19 | */ | 19 | */ |
20 | 20 | ||
21 | /* | 21 | /* |
22 | Enhanced Version of the file for platform independent KDE tools. | 22 | Enhanced Version of the file for platform independent KDE tools. |
23 | Copyright (c) 2004 Ulf Schenk | 23 | Copyright (c) 2004 Ulf Schenk |
24 | 24 | ||
25 | $Id$ | 25 | $Id$ |
26 | */ | 26 | */ |
27 | 27 | ||
28 | #ifndef KABC_FIELD_H | 28 | #ifndef KABC_FIELD_H |
29 | #define KABC_FIELD_H | 29 | #define KABC_FIELD_H |
30 | 30 | ||
31 | #include <qstring.h> | 31 | #include <qstring.h> |
32 | #include <qvaluelist.h> | 32 | #include <q3valuelist.h> |
33 | 33 | ||
34 | #include "addressee.h" | 34 | #include "addressee.h" |
35 | 35 | ||
36 | class KConfig; | 36 | class KConfig; |
37 | 37 | ||
38 | namespace KABC { | 38 | namespace KABC { |
39 | 39 | ||
40 | class Field | 40 | class Field |
41 | { | 41 | { |
42 | class FieldImpl; | 42 | class FieldImpl; |
43 | friend class FieldImpl; | 43 | friend class FieldImpl; |
44 | 44 | ||
45 | public: | 45 | public: |
46 | typedef QValueList<Field *> List; | 46 | typedef Q3ValueList<Field *> List; |
47 | 47 | ||
48 | /** | 48 | /** |
49 | * @li @p All - | 49 | * @li @p All - |
50 | * @li @p Frequent - | 50 | * @li @p Frequent - |
51 | * @li @p Address - | 51 | * @li @p Address - |
52 | * @li @p Email - | 52 | * @li @p Email - |
53 | * @li @p Personal - | 53 | * @li @p Personal - |
54 | * @li @p Organization - | 54 | * @li @p Organization - |
55 | * @li @p CustomCategory - | 55 | * @li @p CustomCategory - |
56 | */ | 56 | */ |
57 | enum FieldCategory | 57 | enum FieldCategory |
58 | { | 58 | { |
59 | All = 0x0, | 59 | All = 0x0, |
60 | Frequent = 0x01, | 60 | Frequent = 0x01, |
61 | Address = 0x02, | 61 | Address = 0x02, |
62 | Email = 0x04, | 62 | Email = 0x04, |
63 | Personal = 0x08, | 63 | Personal = 0x08, |
64 | Organization = 0x10, | 64 | Organization = 0x10, |
65 | CustomCategory = 0x20 | 65 | CustomCategory = 0x20 |
66 | }; | 66 | }; |
67 | 67 | ||
68 | /** | 68 | /** |
69 | * Returns the translated label for this field. | 69 | * Returns the translated label for this field. |
70 | */ | 70 | */ |
71 | virtual QString label(); | 71 | virtual QString label(); |
72 | 72 | ||
73 | /** | 73 | /** |
74 | * Returns the ored categories the field belongs to. | 74 | * Returns the ored categories the field belongs to. |
75 | */ | 75 | */ |
76 | virtual int category(); | 76 | virtual int category(); |
77 | 77 | ||
78 | /** | 78 | /** |
79 | * Returns the translated label for field category. | 79 | * Returns the translated label for field category. |
80 | */ | 80 | */ |
81 | static QString categoryLabel( int category ); | 81 | static QString categoryLabel( int category ); |
82 | 82 | ||
83 | /** | 83 | /** |
84 | * Returns a string representation of the value the field has in the given | 84 | * Returns a string representation of the value the field has in the given |
85 | * Addressee. Returns QString::null, if it is not possible to convert the | 85 | * Addressee. Returns QString::null, if it is not possible to convert the |
86 | * value to a string. | 86 | * value to a string. |
87 | */ | 87 | */ |
88 | virtual QString value( const KABC::Addressee & ); | 88 | virtual QString value( const KABC::Addressee & ); |
89 | 89 | ||
90 | /** | 90 | /** |
91 | * Sets the value of the field in the given Addressee. Returns true on success | 91 | * Sets the value of the field in the given Addressee. Returns true on success |
92 | * or false, if the given string couldn't be converted to a valid value. | 92 | * or false, if the given string couldn't be converted to a valid value. |
93 | */ | 93 | */ |
94 | virtual bool setValue( KABC::Addressee &, const QString & ); | 94 | virtual bool setValue( KABC::Addressee &, const QString & ); |
95 | 95 | ||
96 | /** | 96 | /** |
97 | * Returns, if the field is a user-defined field. | 97 | * Returns, if the field is a user-defined field. |
98 | */ | 98 | */ |
99 | virtual bool isCustom(); | 99 | virtual bool isCustom(); |
100 | 100 | ||
101 | /** | 101 | /** |
102 | * Returns, if the field is equal with @param field. | 102 | * Returns, if the field is equal with @param field. |
103 | */ | 103 | */ |
104 | virtual bool equals( Field *field ); | 104 | virtual bool equals( Field *field ); |
105 | 105 | ||
106 | /** | 106 | /** |
107 | * Returns a list of all fields. | 107 | * Returns a list of all fields. |
108 | */ | 108 | */ |
109 | static Field::List allFields(); | 109 | static Field::List allFields(); |
110 | 110 | ||