Don't set initial size as min size for top level windows in wxMSW.
This was accidentally done because wxWindowBase::CreateBase() didn't recognize the window as being top level as it was called before the window was appended to wxTopLevelWindows list. Fix this by doing the same thing wxGTK already did: just call wxTopLevelWindows.Append() before CreateBase(). git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63188 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -482,12 +482,15 @@ bool wxTopLevelWindowMSW::Create(wxWindow *parent,
|
||||
sizeReal.SetDefaults(GetDefaultSize());
|
||||
}
|
||||
|
||||
// notice that we should append this window to wxTopLevelWindows list
|
||||
// before calling CreateBase() as it behaves differently for TLW and
|
||||
// non-TLW windows
|
||||
wxTopLevelWindows.Append(this);
|
||||
|
||||
bool ret = CreateBase(parent, id, pos, sizeReal, style, name);
|
||||
if ( !ret )
|
||||
return false;
|
||||
|
||||
wxTopLevelWindows.Append(this);
|
||||
|
||||
if ( parent )
|
||||
parent->AddChild(this);
|
||||
|
||||
|
Reference in New Issue
Block a user