X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/30715fa19575aca89b9fee91cdd3d7f0d295548e..210bb741b94a7a4a015de730017c3576afe7a8f1:/include/wx/dataview.h diff --git a/include/wx/dataview.h b/include/wx/dataview.h index 1d9e87ed98..b802aad14f 100644 --- a/include/wx/dataview.h +++ b/include/wx/dataview.h @@ -82,7 +82,7 @@ class WXDLLIMPEXP_ADV wxDataViewListModelNotifier: public wxObject { public: wxDataViewListModelNotifier() { } - virtual ~wxDataViewListModelNotifier() { } + virtual ~wxDataViewListModelNotifier() { m_owner = NULL; } virtual bool RowAppended() = 0; virtual bool RowPrepended() = 0; @@ -92,8 +92,6 @@ public: virtual bool ValueChanged( unsigned int col, unsigned int row ) = 0; virtual bool RowsReordered( unsigned int *new_order ) = 0; virtual bool Cleared() = 0; - virtual bool Freed() - { m_owner = NULL; return true; } void SetOwner( wxDataViewListModel *owner ) { m_owner = owner; } wxDataViewListModel *GetOwner() { return m_owner; } @@ -140,7 +138,7 @@ public: virtual void GetValue( wxVariant &variant, unsigned int col, unsigned int row ) const = 0; // set value, call ValueChanged() afterwards! - virtual bool SetValue( wxVariant &variant, unsigned int col, unsigned int row ) = 0; + virtual bool SetValue( const wxVariant &variant, unsigned int col, unsigned int row ) = 0; // delegated notifiers virtual bool RowAppended(); @@ -200,7 +198,7 @@ public: virtual void GetValue( wxVariant &variant, unsigned int col, unsigned int row ) const; // set value, call ValueChanged() afterwards! - virtual bool SetValue( wxVariant &variant, unsigned int col, unsigned int row ); + virtual bool SetValue( const wxVariant &variant, unsigned int col, unsigned int row ); // called from user virtual bool RowAppended(); @@ -223,6 +221,8 @@ public: bool ChildCleared(); virtual void Resort(); + + void DetachChild(); private: bool m_ascending; @@ -311,9 +311,12 @@ public: // in-place editing virtual bool HasEditorCtrl() { return false; } - virtual wxControl* CreateEditorCtrl( wxWindow *parent, wxRect labelRect, const wxVariant &value ) + virtual wxControl* CreateEditorCtrl(wxWindow * WXUNUSED(parent), + wxRect WXUNUSED(labelRect), + const wxVariant& WXUNUSED(value)) { return NULL; } - virtual bool GetValueFromEditorCtrl( wxControl* editor, wxVariant &value ) + virtual bool GetValueFromEditorCtrl(wxControl * WXUNUSED(editor), + wxVariant& WXUNUSED(value)) { return false; } virtual bool StartEditing( unsigned int row, wxRect labelRect );