author | tille <tille> | 2003-05-08 12:16:38 (UTC) |
---|---|---|
committer | tille <tille> | 2003-05-08 12:16:38 (UTC) |
commit | 763d7d7da84682fb87a631a997e93c08f5abde61 (patch) (unidiff) | |
tree | 9cfeb731b793e3634fa751a6b6ffce63609f24a2 /core/pim/osearch/datebooksearch.cpp | |
parent | 9e08dd00a96ffb4141da9f4ce2df0b871b334691 (diff) | |
download | opie-763d7d7da84682fb87a631a997e93c08f5abde61.zip opie-763d7d7da84682fb87a631a997e93c08f5abde61.tar.gz opie-763d7d7da84682fb87a631a997e93c08f5abde61.tar.bz2 |
this needs the new libopie patch...
Diffstat (limited to 'core/pim/osearch/datebooksearch.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/pim/osearch/datebooksearch.cpp | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/core/pim/osearch/datebooksearch.cpp b/core/pim/osearch/datebooksearch.cpp index 85c55c2..e60a3b1 100644 --- a/core/pim/osearch/datebooksearch.cpp +++ b/core/pim/osearch/datebooksearch.cpp | |||
@@ -38,22 +38,26 @@ void DatebookSearch::expand() | |||
38 | _dates->load(); | 38 | _dates->load(); |
39 | } | 39 | } |
40 | 40 | #define LIPBOPIE_SEARCH | |
41 | #ifdef LIPBOPIE_SEARCH | ||
42 | ORecordList<OEvent> results = _dates->matchRegexp(_search); | ||
43 | for (uint i = 0; i < results.count(); i++) { | ||
44 | new EventItem( this, new OEvent( results[i] )); | ||
45 | } | ||
46 | #else | ||
41 | ORecordList<OEvent> list = _dates->allRecords(); | 47 | ORecordList<OEvent> list = _dates->allRecords(); |
42 | QArray<int> m_currentQuery( list.count() ); | 48 | QArray<int> m_currentQuery( list.count() ); |
43 | for( uint i=0; i<list.count(); i++ ){ | 49 | for( uint i=0; i<list.count(); i++ ){ |
44 | 50 | //qDebug("datebook: %s",list[i].description().latin1() ); | |
45 | if ( | 51 | if ( |
46 | ( list[i].description().contains( _search ) ) || | 52 | ( list[i].description().contains( _search ) ) || |
47 | ( list[i].note().contains( _search ) ) || | 53 | ( list[i].note().contains( _search ) ) || |
48 | ( list[i].location().contains( _search ) ) | 54 | ( list[i].location().contains( _search ) ) |
49 | // ( _search.find( list[i].description(), 0 ) > 0 ) || | ||
50 | // ( _search.find( list[i].note(), 0 ) > 0 ) || | ||
51 | // ( _search.find( list[i].location(), 0 ) > 0 ) | ||
52 | ){ | 55 | ){ |
56 | //qDebug("FOUND"); | ||
53 | new EventItem( this, new OEvent( list[i] ) ); | 57 | new EventItem( this, new OEvent( list[i] ) ); |
54 | // new OListViewItem( this, list[i].description() ); | ||
55 | } | 58 | } |
56 | 59 | ||
57 | } | 60 | } |
61 | #endif | ||
58 | } | 62 | } |
59 | 63 | ||