just return the min size needed by the sizer for the windows with sizers from their DoGetBestSize() instead of adjusting it upwards to the current size via GetWindowSizeForVirtualSize() call: this might be wrong as it could reintroduce the bug fixed in rev 1.66 of src/generic/scrlwing.cpp (but it's not really clear just what exactly this bug was) but the existing code was definitely wrong as the best size of the window must not change as it's being resized
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45864 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
d296fd8ff7
commit
7e0f753950
@ -483,18 +483,7 @@ wxSize wxWindowBase::DoGetBestSize() const
|
||||
|
||||
if ( m_windowSizer )
|
||||
{
|
||||
// Adjust to window size, since the return value of GetWindowSizeForVirtualSize is
|
||||
// expressed in window and not client size
|
||||
wxSize minSize = m_windowSizer->GetMinSize();
|
||||
wxSize size(GetSize());
|
||||
wxSize clientSize(GetClientSize());
|
||||
|
||||
wxSize minWindowSize(minSize.x + size.x - clientSize.x,
|
||||
minSize.y + size.y - clientSize.y);
|
||||
|
||||
best = GetWindowSizeForVirtualSize(minWindowSize);
|
||||
|
||||
return best;
|
||||
best = m_windowSizer->GetMinSize();
|
||||
}
|
||||
#if wxUSE_CONSTRAINTS
|
||||
else if ( m_constraints )
|
||||
|
Loading…
Reference in New Issue
Block a user