Also get header button height right
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@50926 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1281,14 +1281,16 @@ bool wxDataViewHeaderWindowMSW::Create( wxDataViewCtrl *parent, wxWindowID id,
|
|||||||
m_owner = parent;
|
m_owner = parent;
|
||||||
|
|
||||||
m_scrollOffsetX = 0;
|
m_scrollOffsetX = 0;
|
||||||
m_buttonHeight = wxRendererNative::Get().GetHeaderButtonHeight( this ) + 10;
|
m_buttonHeight = wxRendererNative::Get().GetHeaderButtonHeight( this );
|
||||||
|
|
||||||
int x = pos.x == wxDefaultCoord ? 0 : pos.x,
|
int x = pos.x == wxDefaultCoord ? 0 : pos.x,
|
||||||
y = pos.y == wxDefaultCoord ? 0 : pos.y,
|
y = pos.y == wxDefaultCoord ? 0 : pos.y,
|
||||||
w = size.x == wxDefaultCoord ? 1 : size.x,
|
w = size.x == wxDefaultCoord ? 1 : size.x,
|
||||||
h = size.y == wxDefaultCoord ? m_buttonHeight : size.y;
|
h = m_buttonHeight;
|
||||||
|
|
||||||
if ( !CreateControl(parent, id, pos, size, 0, wxDefaultValidator, name) )
|
wxSize new_size(w,h);
|
||||||
|
|
||||||
|
if ( !CreateControl(parent, id, pos, new_size, 0, wxDefaultValidator, name) )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
// create the native WC_HEADER window:
|
// create the native WC_HEADER window:
|
||||||
|
Reference in New Issue
Block a user