Add wxDataViewRendererBase::PrepareForItem() helper.

For calling SetValue() and SetAttr() consistently, instead of having the
same code duplicated all over the place.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65950 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík
2010-10-30 15:57:55 +00:00
parent 86755098f5
commit f0ccd2cbfa
3 changed files with 25 additions and 52 deletions

View File

@@ -118,6 +118,10 @@ public:
wxString GetVariantType() const { return m_variantType; }
// helper that calls SetValue and SetAttr:
void PrepareForItem(const wxDataViewModel *model,
const wxDataViewItem& item, unsigned column);
// renderer properties:
virtual void SetMode( wxDataViewCellMode mode ) = 0;
virtual wxDataViewCellMode GetMode() const = 0;