Don't send any cache hint events for empty wxDataViewCtrl. Sending them was
unnecessary, inconsistent with wxListCtrl (which doesn't send them when it's
empty) and the events also had incorrect range. Just don't create them at all
to avoid all these problems at once.
Closes #13132.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67591
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
dc.DrawRectangle(GetClientSize());
#endif
+ if ( IsEmpty() )
+ {
+ // No items to draw.
+ return;
+ }
+
// prepare the DC
GetOwner()->PrepareDC( dc );
dc.SetFont( GetFont() );