Moved more code from wxDataViewCtrl to wxDataViewCtrlInternal.

Add new special API for wxDataViewVirtualIndexModel::Reset() as
wxDataViewModel::Clear is something different and needs a different, two
step API under GTK+, one for destroying the current view and one for
rereading the new contents.
Added ::BeforeReset() and ::AfterReset() notifications for that purpose.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65533 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling
2010-09-12 20:07:28 +00:00
parent 5249673498
commit 673810eeb8
4 changed files with 136 additions and 68 deletions

View File

@@ -125,6 +125,10 @@ public:
virtual bool ItemsChanged( const wxDataViewItemArray &items );
virtual bool ValueChanged( const wxDataViewItem &item, unsigned int col ) = 0;
virtual bool Cleared() = 0;
// this is needed for the virtual list model under GTK+
virtual bool BeforeReset( size_t WXUNUSED(old_size), size_t WXUNUSED(new_size) ) { return true; }
virtual bool AfterReset() { return Cleared(); }
virtual void Resort() = 0;
@@ -245,7 +249,12 @@ public:
bool ValueChanged( const wxDataViewItem &item, unsigned int col );
bool Cleared();
// delegatd action
// this is needed for the virtual list model under GTK+
bool BeforeReset( size_t old_size, size_t new_size );
bool AfterReset();
// delegated action
virtual void Resort();
void AddNotifier( wxDataViewModelNotifier *notifier );