temp [non] fix for wxTLW [non] creation under wxMSW

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@11754 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 2001-09-30 22:25:32 +00:00
parent be71e18af4
commit 7ee7c43f7e

View File

@ -45,7 +45,6 @@ END_EVENT_TABLE()
WX_FORWARD_TO_INPUT_CONSUMER(wxTopLevelWindow)
// ============================================================================
// implementation
// ============================================================================
@ -63,7 +62,7 @@ bool wxTopLevelWindow::Create(wxWindow *parent,
wxWindowID id,
const wxString& title,
const wxPoint& pos,
const wxSize& sizeOrig,
const wxSize& size,
long style,
const wxString &name)
{
@ -91,9 +90,18 @@ bool wxTopLevelWindow::Create(wxWindow *parent,
}
if ( !wxTopLevelWindowNative::Create(parent, id, title, pos,
sizeOrig, style, name) )
size, style, name) )
return FALSE;
// FIXME: to be removed as soon as wxTLW/wxFrame/wxDialog creation code in
// wxMSW is rationalized
#ifdef __WXMSW__
extern const wxChar *wxFrameClassName;
if ( !MSWCreate(id, NULL, wxFrameClassName, this, title,
pos.x, pos.y, size.x, size.y, style) )
return FALSE;
#endif // __WXMSW__
if ( ms_drawDecorations )
{
m_windowStyle = styleOrig;
@ -320,12 +328,14 @@ bool wxTopLevelWindow::PerformAction(const wxControlAction& action,
long numArg,
const wxString& strArg)
{
bool isActive = numArg != 0;
if ( action == wxACTION_TOPLEVEL_ACTIVATE )
{
if ( m_isActive != (bool)numArg )
if ( m_isActive != isActive )
{
Refresh();
m_isActive = (bool)numArg;
m_isActive = isActive;
wxNcPaintEvent event(GetId());
event.SetEventObject(this);
GetEventHandler()->ProcessEvent(event);