author | zecke <zecke> | 2002-09-25 11:59:24 (UTC) |
---|---|---|
committer | zecke <zecke> | 2002-09-25 11:59:24 (UTC) |
commit | 38240090027bd68d8dd15d7d46ecf17792edb732 (patch) (side-by-side diff) | |
tree | 589ef486d7169c57592ed8667f6c84d43f882d48 /libopie2/opiepim/orecordlist.h | |
parent | 5f2dd0a2340914b4983ebce3813187034e2cb9dc (diff) | |
download | opie-38240090027bd68d8dd15d7d46ecf17792edb732.zip opie-38240090027bd68d8dd15d7d46ecf17792edb732.tar.gz opie-38240090027bd68d8dd15d7d46ecf17792edb732.tar.bz2 |
Add a sort function and filter function to TodoAccess
This would allow us todo a paint hack in QTable
Diffstat (limited to 'libopie2/opiepim/orecordlist.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libopie2/opiepim/orecordlist.h | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/libopie2/opiepim/orecordlist.h b/libopie2/opiepim/orecordlist.h index c63d813..1fd0741 100644 --- a/libopie2/opiepim/orecordlist.h +++ b/libopie2/opiepim/orecordlist.h @@ -47,15 +47,15 @@ public: bool operator==( const ORecordListIterator& it ); bool operator!=( const ORecordListIterator& it ); - + /** * the current item */ uint current()const; - + /** * the number of items */ uint count()const; - + /** * sets the current item @@ -102,10 +102,11 @@ public: */ Iterator end(); - + /** * the number of items in the list */ uint count()const; - + + T operator[]( uint i ); // FIXME implemenent remove /* @@ -147,5 +148,5 @@ ORecordListIterator<T> &ORecordListIterator<T>::operator=( const ORecordListIter m_temp = it.m_temp; m_end = it.m_end; -// m_record = it.m_record; + m_record = it.m_record; return *this; @@ -253,3 +254,7 @@ uint ORecordList<T>::count()const { return m_ids.count(); } +template <class T> +T ORecordList<T>::operator[]( uint i ) { + return m_acc->find( m_ids[i] ); +} #endif |