Don't assert in wxRenderer::GetHeaderButtonMargin()
Even if we don't have any way to determine the real margin, don't assert in this method implementation in wxGTK and wxOSX, but just return 0 instead. This fixes asserts when trying to fit a column of wxDataViewCtrl, by double clicking a separator after it, to its contents. See #13685.
This commit is contained in:
@@ -269,8 +269,7 @@ int wxRendererGTK::GetHeaderButtonHeight(wxWindow *WXUNUSED(win))
|
|||||||
|
|
||||||
int wxRendererGTK::GetHeaderButtonMargin(wxWindow *WXUNUSED(win))
|
int wxRendererGTK::GetHeaderButtonMargin(wxWindow *WXUNUSED(win))
|
||||||
{
|
{
|
||||||
wxFAIL_MSG( "GetHeaderButtonMargin() not implemented" );
|
return 0; // TODO: How to determine the real margin?
|
||||||
return -1;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@@ -251,8 +251,7 @@ int wxRendererMac::GetHeaderButtonHeight(wxWindow* WXUNUSED(win))
|
|||||||
|
|
||||||
int wxRendererMac::GetHeaderButtonMargin(wxWindow *WXUNUSED(win))
|
int wxRendererMac::GetHeaderButtonMargin(wxWindow *WXUNUSED(win))
|
||||||
{
|
{
|
||||||
wxFAIL_MSG( "GetHeaderButtonMargin() not implemented" );
|
return 0; // TODO: How to determine the real margin?
|
||||||
return -1;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxRendererMac::DrawTreeItemButton( wxWindow *win,
|
void wxRendererMac::DrawTreeItemButton( wxWindow *win,
|
||||||
|
Reference in New Issue
Block a user