author | coredump <coredump> | 2003-12-08 16:27:39 (UTC) |
---|---|---|
committer | coredump <coredump> | 2003-12-08 16:27:39 (UTC) |
commit | 40eab6d033e060347c83adb707364933d2a77f30 (patch) (unidiff) | |
tree | d4c59e570257444a3b76b0fabb46184e0e7cecaa /core/pim/osearch/adresssearch.cpp | |
parent | 466d396717be9ec10bdc1472bce5e733cd268ce4 (diff) | |
download | opie-40eab6d033e060347c83adb707364933d2a77f30.zip opie-40eab6d033e060347c83adb707364933d2a77f30.tar.gz opie-40eab6d033e060347c83adb707364933d2a77f30.tar.bz2 |
Appearance fixed for osearch
Diffstat (limited to 'core/pim/osearch/adresssearch.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/pim/osearch/adresssearch.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/pim/osearch/adresssearch.cpp b/core/pim/osearch/adresssearch.cpp index f117fe6..7681ea2 100644 --- a/core/pim/osearch/adresssearch.cpp +++ b/core/pim/osearch/adresssearch.cpp | |||
@@ -1,60 +1,62 @@ | |||
1 | // | 1 | // |
2 | // | 2 | // |
3 | // C++ Implementation: $MODULE$ | 3 | // C++ Implementation: $MODULE$ |
4 | // | 4 | // |
5 | // Description: | 5 | // Description: |
6 | // | 6 | // |
7 | // | 7 | // |
8 | // Author: Patrick S. Vogt <tille@handhelds.org>, (C) 2003 | 8 | // Author: Patrick S. Vogt <tille@handhelds.org>, (C) 2003 |
9 | // | 9 | // |
10 | // Copyright: See COPYING file that comes with this distribution | 10 | // Copyright: See COPYING file that comes with this distribution |
11 | // | 11 | // |
12 | // | 12 | // |
13 | #include "adresssearch.h" | 13 | #include "adresssearch.h" |
14 | 14 | ||
15 | #include <qstring.h> | 15 | #include <qstring.h> |
16 | #include <qiconset.h> | 16 | #include <qiconset.h> |
17 | //#include <qwhatsthis.h> | 17 | //#include <qwhatsthis.h> |
18 | #include <qpe/resource.h> | 18 | #include <qpe/resource.h> |
19 | #include <opie/ocontactaccess.h> | 19 | #include <opie/ocontactaccess.h> |
20 | 20 | ||
21 | #include "contactitem.h" | 21 | #include "contactitem.h" |
22 | 22 | ||
23 | AdressSearch::AdressSearch(QListView* parent, QString name): | 23 | AdressSearch::AdressSearch(QListView* parent, QString name): |
24 | SearchGroup(parent, name) | 24 | SearchGroup(parent, name) |
25 | { | 25 | { |
26 | _contacts = 0; | 26 | _contacts = 0; |
27 | QIconSet is = Resource::loadIconSet( "addressbook/AddressBook" ); | 27 | QIconSet is = Resource::loadIconSet( "addressbook/AddressBookSmall" ); |
28 | setPixmap( 0, is.pixmap( QIconSet::Small, true ) ); | 28 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); |
29 | |||
30 | |||
29 | //QWhatsThis::add( this, QObject::tr("Search the addressbook") ); | 31 | //QWhatsThis::add( this, QObject::tr("Search the addressbook") ); |
30 | /*QPixmap pix = Resource::loadPixmap( "addressbook/AddressBook" ); | 32 | /*QPixmap pix = Resource::loadPixmap( "addressbook/AddressBook" ); |
31 | QImage img = pix.convertToImage(); | 33 | QImage img = pix.convertToImage(); |
32 | img.smoothScale( 14, 14 ); | 34 | img.smoothScale( 14, 14 ); |
33 | pix.convertFromImage( img ); | 35 | pix.convertFromImage( img ); |
34 | setPixmap( 0, pix );*/ | 36 | setPixmap( 0, pix );*/ |
35 | } | 37 | } |
36 | 38 | ||
37 | 39 | ||
38 | AdressSearch::~AdressSearch() | 40 | AdressSearch::~AdressSearch() |
39 | { | 41 | { |
40 | delete _contacts; | 42 | delete _contacts; |
41 | } | 43 | } |
42 | 44 | ||
43 | void AdressSearch::load() | 45 | void AdressSearch::load() |
44 | { | 46 | { |
45 | _contacts = new OContactAccess("osearch"); | 47 | _contacts = new OContactAccess("osearch"); |
46 | } | 48 | } |
47 | 49 | ||
48 | int AdressSearch::search() | 50 | int AdressSearch::search() |
49 | { | 51 | { |
50 | ORecordList<OContact> results = _contacts->matchRegexp(_search); | 52 | ORecordList<OContact> results = _contacts->matchRegexp(_search); |
51 | for (uint i = 0; i < results.count(); i++) { | 53 | for (uint i = 0; i < results.count(); i++) { |
52 | (void)new ContactItem( this, new OContact( results[i] )); | 54 | (void)new ContactItem( this, new OContact( results[i] )); |
53 | } | 55 | } |
54 | return results.count(); | 56 | return results.count(); |
55 | } | 57 | } |
56 | 58 | ||
57 | void AdressSearch::insertItem( void* ) | 59 | void AdressSearch::insertItem( void* ) |
58 | { | 60 | { |
59 | 61 | ||
60 | } | 62 | } |