author | eilers <eilers> | 2003-08-01 12:30:16 (UTC) |
---|---|---|
committer | eilers <eilers> | 2003-08-01 12:30:16 (UTC) |
commit | 6c715b67a8f0e32a4edca5be91332622834c8d91 (patch) (unidiff) | |
tree | ae2d660e1fd9c990c2d725c075ce6c42480b0af8 /libopie2/opiepim/orecordlist.h | |
parent | cb45aa10043fdd6fddcab42ef0e07ddafc3d506d (diff) | |
download | opie-6c715b67a8f0e32a4edca5be91332622834c8d91.zip opie-6c715b67a8f0e32a4edca5be91332622834c8d91.tar.gz opie-6c715b67a8f0e32a4edca5be91332622834c8d91.tar.bz2 |
Merging changes from BRANCH_1_0 to HEAD
Diffstat (limited to 'libopie2/opiepim/orecordlist.h') (more/less context) (show whitespace changes)
-rw-r--r-- | libopie2/opiepim/orecordlist.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/libopie2/opiepim/orecordlist.h b/libopie2/opiepim/orecordlist.h index edcd729..5211f57 100644 --- a/libopie2/opiepim/orecordlist.h +++ b/libopie2/opiepim/orecordlist.h | |||
@@ -7,6 +7,7 @@ | |||
7 | #include "otemplatebase.h" | 7 | #include "otemplatebase.h" |
8 | #include "opimrecord.h" | 8 | #include "opimrecord.h" |
9 | 9 | ||
10 | class ORecordListIteratorPrivate; | ||
10 | /** | 11 | /** |
11 | * Our List Iterator | 12 | * Our List Iterator |
12 | * it behaves like STL or Qt | 13 | * it behaves like STL or Qt |
@@ -71,9 +72,10 @@ private: | |||
71 | bool m_direction :1; | 72 | bool m_direction :1; |
72 | 73 | ||
73 | /* d pointer for future versions */ | 74 | /* d pointer for future versions */ |
74 | class IteratorPrivate; | 75 | ORecordListIteratorPrivate *d; |
75 | IteratorPrivate *d; | ||
76 | }; | 76 | }; |
77 | |||
78 | class ORecordListPrivate; | ||
77 | /** | 79 | /** |
78 | * The recordlist used as a return type | 80 | * The recordlist used as a return type |
79 | * from OPimAccessTemplate | 81 | * from OPimAccessTemplate |
@@ -123,6 +125,7 @@ ORecordList( const QArray<int>& ids, | |||
123 | private: | 125 | private: |
124 | QArray<int> m_ids; | 126 | QArray<int> m_ids; |
125 | const Base* m_acc; | 127 | const Base* m_acc; |
128 | ORecordListPrivate *d; | ||
126 | }; | 129 | }; |
127 | 130 | ||
128 | /* ok now implement it */ | 131 | /* ok now implement it */ |
@@ -220,6 +223,9 @@ ORecordListIterator<T>::ORecordListIterator( const QArray<int> uids, | |||
220 | : m_uids( uids ), m_current( 0 ), m_temp( t ), m_end( false ), | 223 | : m_uids( uids ), m_current( 0 ), m_temp( t ), m_end( false ), |
221 | m_direction( false ) | 224 | m_direction( false ) |
222 | { | 225 | { |
226 | /* if the list is empty we're already at the end of the list */ | ||
227 | if (uids.count() == 0 ) | ||
228 | m_end = true; | ||
223 | } | 229 | } |
224 | template <class T> | 230 | template <class T> |
225 | uint ORecordListIterator<T>::current()const { | 231 | uint ORecordListIterator<T>::current()const { |