+// wxDataViewBitmapRenderer
+// ---------------------------------------------------------
+
+IMPLEMENT_CLASS(wxDataViewBitmapRenderer, wxDataViewCustomRenderer)
+
+wxDataViewBitmapRenderer::wxDataViewBitmapRenderer( const wxString &varianttype, wxDataViewCellMode mode ) :
+ wxDataViewCustomRenderer( varianttype, mode )
+{
+}
+
+bool wxDataViewBitmapRenderer::SetValue( const wxVariant &value )
+{
+ if (value.GetType() == wxT("wxBitmap"))
+ m_bitmap << value;
+ if (value.GetType() == wxT("wxIcon"))
+ m_icon << value;
+
+ return true;
+}
+
+bool wxDataViewBitmapRenderer::GetValue( wxVariant& WXUNUSED(value) )
+{
+ return false;
+}
+
+bool wxDataViewBitmapRenderer::Render( wxRect cell, wxDC *dc, int WXUNUSED(state) )
+{
+ if (m_bitmap.Ok())
+ dc->DrawBitmap( m_bitmap, cell.x, cell.y );
+ else if (m_icon.Ok())
+ dc->DrawIcon( m_icon, cell.x, cell.y );
+
+ return true;
+}
+
+wxSize wxDataViewBitmapRenderer::GetSize()
+{
+ if (m_bitmap.Ok())
+ return wxSize( m_bitmap.GetWidth(), m_bitmap.GetHeight() );
+ else if (m_icon.Ok())
+ return wxSize( m_icon.GetWidth(), m_icon.GetHeight() );
+
+ return wxSize(16,16);
+}
+
+// ---------------------------------------------------------
+// wxDataViewToggleRenderer