- citer Append( elT e ) { push_back( e ); return GetLast(); } \
- void Clear() { clear(); } \
- size_t GetCount() const { return size(); } \
- citer GetFirst() const { return citer( this, ((liT*)this)->begin() ); } \
- citer GetLast() const { return citer( this, --(((liT*)this)->end()) ); } \
- bool IsEmpty() const { return empty(); } \
- bool DeleteObject( elT e ) \
+ bool IsEmpty() const \
+ { return empty(); } \
+ size_t GetCount() const \
+ { return size(); } \
+ int Number() const \
+ { return static_cast< int >( GetCount() ); } \
+ \
+ compatibility_iterator Item( size_t idx ) const \
+ { \
+ iterator i = const_cast< liT* >(this)->begin(); \
+ std::advance( i, idx ); \
+ return compatibility_iterator( this, i ); \
+ } \
+ elT operator[](size_t idx) const \
+ { \
+ return Item(idx).GetData(); \
+ } \
+ \
+ compatibility_iterator GetFirst() const \
+ { \
+ return compatibility_iterator( this, \
+ const_cast< liT* >(this)->begin() ); \
+ } \
+ compatibility_iterator GetLast() const \
+ { \
+ iterator i = const_cast< liT* >(this)->end(); \
+ return compatibility_iterator( this, !empty() ? --i : i ); \
+ } \
+ compatibility_iterator Member( elT e ) const \
+ { return Find( e ); } \
+ compatibility_iterator Nth( int n ) const \
+ { return Item( n ); } \
+ int IndexOf( elT e ) const \
+ { return Find( e ).IndexOf(); } \
+ \
+ compatibility_iterator Append( elT e ) \
+ { \
+ push_back( e ); \
+ return GetLast(); \
+ } \
+ compatibility_iterator Insert( elT e ) \
+ { \
+ push_front( e ); \
+ return compatibility_iterator( this, begin() ); \
+ } \
+ compatibility_iterator Insert( compatibility_iterator & i, elT e ) \
+ { \
+ return compatibility_iterator( this, insert( i.m_iter, e ) ); \
+ } \
+ compatibility_iterator Insert( size_t idx, elT e ) \
+ { \
+ return compatibility_iterator( this, \
+ insert( Item( idx ).m_iter, e ) ); \
+ } \
+ \
+ void DeleteContents( bool destroy ) \
+ { m_destroy = destroy; } \
+ bool GetDeleteContents() const \
+ { return m_destroy; } \
+ void Erase( const compatibility_iterator& i ) \
+ { \
+ if ( m_destroy ) \
+ _WX_LIST_HELPER_##liT::DeleteFunction( i->GetData() ); \
+ erase( i.m_iter ); \
+ } \
+ bool DeleteNode( const compatibility_iterator& i ) \