fixed wxSpinCtrl's client size computation in wxMSW to return something sensible
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@50552 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -643,6 +643,19 @@ void wxSpinCtrl::DoGetSize(int *x, int *y) const
|
||||
*y = ctrlrect.bottom - ctrlrect.top;
|
||||
}
|
||||
|
||||
void wxSpinCtrl::DoGetClientSize(int *x, int *y) const
|
||||
{
|
||||
RECT spinrect = wxGetClientRect(GetHwnd());
|
||||
RECT textrect = wxGetClientRect(GetBuddyHwnd());
|
||||
RECT ctrlrect;
|
||||
UnionRect(&ctrlrect,&textrect, &spinrect);
|
||||
|
||||
if ( x )
|
||||
*x = ctrlrect.right - ctrlrect.left;
|
||||
if ( y )
|
||||
*y = ctrlrect.bottom - ctrlrect.top;
|
||||
}
|
||||
|
||||
void wxSpinCtrl::DoGetPosition(int *x, int *y) const
|
||||
{
|
||||
// hack: pretend that our HWND is the text control just for a moment
|
||||
|
Reference in New Issue
Block a user