summaryrefslogtreecommitdiff
path: root/noncore/unsupported/mailit/addresslist.h
authorllornkcor <llornkcor>2003-05-24 01:20:33 (UTC)
committer llornkcor <llornkcor>2003-05-24 01:20:33 (UTC)
commit62d2ddfb5cd77e2637cdf7fe16d76aac04975984 (patch) (unidiff)
tree2157d57bab2d6e491226f5bc8468a4c2527e1456 /noncore/unsupported/mailit/addresslist.h
parent0c4b5288ccd4bcd1668816a0c4e12ce0a76b4e6e (diff)
downloadopie-62d2ddfb5cd77e2637cdf7fe16d76aac04975984.zip
opie-62d2ddfb5cd77e2637cdf7fe16d76aac04975984.tar.gz
opie-62d2ddfb5cd77e2637cdf7fe16d76aac04975984.tar.bz2
QString to const QString
Diffstat (limited to 'noncore/unsupported/mailit/addresslist.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/unsupported/mailit/addresslist.h36
1 files changed, 18 insertions, 18 deletions
diff --git a/noncore/unsupported/mailit/addresslist.h b/noncore/unsupported/mailit/addresslist.h
index 99cef9a..b46d467 100644
--- a/noncore/unsupported/mailit/addresslist.h
+++ b/noncore/unsupported/mailit/addresslist.h
@@ -4,55 +4,55 @@
4** This file is part of Qt Palmtop Environment. 4** This file is part of Qt Palmtop Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software 7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the 8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file. 9** packaging of this file.
10** 10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14** See http://www.trolltech.com/gpl/ for GPL licensing information. 14** See http://www.trolltech.com/gpl/ for GPL licensing information.
15** 15**
16** Contact info@trolltech.com if any conditions of this licensing are 16** Contact info@trolltech.com if any conditions of this licensing are
17** not clear to you. 17** not clear to you.
18** 18**
19**********************************************************************/ 19**********************************************************************/
20#ifndef ADDRESSLIST_H 20#ifndef ADDRESSLIST_H
21#define ADDRESSLIST_H 21#define ADDRESSLIST_H
22 22
23#include <qobject.h> 23#include <qobject.h>
24#include <qlist.h> 24#include <qlist.h>
25 25
26struct Contact 26struct Contact
27{ 27{
28 QString email; 28 QString email;
29 QString name; 29 QString name;
30}; 30};
31 31
32class AddressList : public QObject 32class AddressList : public QObject
33{ 33{
34 Q_OBJECT 34 Q_OBJECT
35 35
36public: 36public:
37 AddressList(); 37 AddressList();
38 ~AddressList(); 38 ~AddressList();
39 void addContact(QString email, QString name); 39 void addContact(const QString &email, const QString &name);
40 bool containsEmail(QString email); 40 bool containsEmail(const QString &email);
41 bool containsName(QString name); 41 bool containsName(const QString &name);
42 QString getNameByEmail(QString email); 42 QString getNameByEmail(const QString &email);
43 QString getEmailByName(QString name); 43 QString getEmailByName(const QString &name);
44 QList<Contact>* getContactList(); 44 QList<Contact>* getContactList();
45 45
46private: 46private:
47 int getEmailRef(QString email); 47 int getEmailRef(const QString &email);
48 int getNameRef(QString name); 48 int getNameRef(const QString &name);
49 QString getRightString(QString in); 49 QString getRightString(const QString &in);
50 void read(); 50 void read();
51 51
52private: 52private:
53 QList<Contact> addresses; 53 QList<Contact> addresses;
54 QString filename; 54 QString filename;
55 bool dirty; 55 bool dirty;
56}; 56};
57 57
58#endif 58#endif