-rw-r--r-- | libopie/pim/orecordlist.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/libopie/pim/orecordlist.h b/libopie/pim/orecordlist.h index 1fd0741..b6fa7fa 100644 --- a/libopie/pim/orecordlist.h +++ b/libopie/pim/orecordlist.h | |||
@@ -133,55 +133,54 @@ ORecordListIterator<T>::~ORecordListIterator() { | |||
133 | 133 | ||
134 | template <class T> | 134 | template <class T> |
135 | ORecordListIterator<T>::ORecordListIterator( const ORecordListIterator<T>& it) { | 135 | ORecordListIterator<T>::ORecordListIterator( const ORecordListIterator<T>& it) { |
136 | // qWarning("ORecordListIterator copy c'tor"); | 136 | // qWarning("ORecordListIterator copy c'tor"); |
137 | m_uids = it.m_uids; | 137 | m_uids = it.m_uids; |
138 | m_current = it.m_current; | 138 | m_current = it.m_current; |
139 | m_temp = it.m_temp; | 139 | m_temp = it.m_temp; |
140 | m_end = it.m_end; | 140 | m_end = it.m_end; |
141 | m_record = it.m_record; | 141 | m_record = it.m_record; |
142 | } | 142 | } |
143 | 143 | ||
144 | template <class T> | 144 | template <class T> |
145 | ORecordListIterator<T> &ORecordListIterator<T>::operator=( const ORecordListIterator<T>& it) { | 145 | ORecordListIterator<T> &ORecordListIterator<T>::operator=( const ORecordListIterator<T>& it) { |
146 | m_uids = it.m_uids; | 146 | m_uids = it.m_uids; |
147 | m_current = it.m_current; | 147 | m_current = it.m_current; |
148 | m_temp = it.m_temp; | 148 | m_temp = it.m_temp; |
149 | m_end = it.m_end; | 149 | m_end = it.m_end; |
150 | m_record = it.m_record; | 150 | m_record = it.m_record; |
151 | 151 | ||
152 | return *this; | 152 | return *this; |
153 | } | 153 | } |
154 | 154 | ||
155 | template <class T> | 155 | template <class T> |
156 | T ORecordListIterator<T>::operator*() { | 156 | T ORecordListIterator<T>::operator*() { |
157 | // qWarning("operator* %d %d", m_current, m_uids[m_current] ); | 157 | qWarning("operator* %d %d", m_current, m_uids[m_current] ); |
158 | if (!m_end ) | 158 | if (!m_end ) |
159 | /* FIXME | 159 | /* FIXME |
160 | * until the cache is in place | 160 | * until the cache is in place |
161 | * we do the uid match uid check | 161 | * we do the uid match uid check |
162 | */ | 162 | */ |
163 | if(m_record.uid() != m_uids[m_current] ) | ||
164 | m_record = m_temp->find( m_uids[m_current] ); | 163 | m_record = m_temp->find( m_uids[m_current] ); |
165 | else | 164 | else |
166 | m_record = T(); | 165 | m_record = T(); |
167 | 166 | ||
168 | return m_record; | 167 | return m_record; |
169 | } | 168 | } |
170 | 169 | ||
171 | template <class T> | 170 | template <class T> |
172 | ORecordListIterator<T> &ORecordListIterator<T>::operator++() { | 171 | ORecordListIterator<T> &ORecordListIterator<T>::operator++() { |
173 | if (m_current < m_uids.count() ) { | 172 | if (m_current < m_uids.count() ) { |
174 | m_end = false; | 173 | m_end = false; |
175 | ++m_current; | 174 | ++m_current; |
176 | }else | 175 | }else |
177 | m_end = true; | 176 | m_end = true; |
178 | 177 | ||
179 | return *this; | 178 | return *this; |
180 | } | 179 | } |
181 | template <class T> | 180 | template <class T> |
182 | ORecordListIterator<T> &ORecordListIterator<T>::operator--() { | 181 | ORecordListIterator<T> &ORecordListIterator<T>::operator--() { |
183 | if ( m_current > 0 ) { | 182 | if ( m_current > 0 ) { |
184 | --m_current; | 183 | --m_current; |
185 | m_end = false; | 184 | m_end = false; |
186 | } else | 185 | } else |
187 | m_end = true; | 186 | m_end = true; |