X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8e877c195bc9ade6d4cb9f96bffb00e81978d740..2e1a688e3e9c6c265620e4f05d579077367e9fdb:/src/motif/frame.cpp diff --git a/src/motif/frame.cpp b/src/motif/frame.cpp index c18c7de83f..f0ddb991e0 100644 --- a/src/motif/frame.cpp +++ b/src/motif/frame.cpp @@ -64,7 +64,7 @@ extern wxList wxPendingDelete; static bool wxTopLevelUsed = FALSE; #if !USE_SHARED_LIBRARY -BEGIN_EVENT_TABLE(wxFrame, wxWindowBase) +BEGIN_EVENT_TABLE(wxFrame, wxWindow) EVT_SIZE(wxFrame::OnSize) EVT_ACTIVATE(wxFrame::OnActivate) EVT_MENU_HIGHLIGHT_ALL(wxFrame::OnMenuHighlight) @@ -73,7 +73,7 @@ BEGIN_EVENT_TABLE(wxFrame, wxWindowBase) EVT_CLOSE(wxFrame::OnCloseWindow) END_EVENT_TABLE() -IMPLEMENT_DYNAMIC_CLASS(wxFrame, wxWindowBase) +IMPLEMENT_DYNAMIC_CLASS(wxFrame, wxWindow) #endif #if wxUSE_NATIVE_STATUSBAR @@ -146,14 +146,16 @@ bool wxFrame::Create(wxWindow *parent, int x = pos.x, y = pos.y; int width = size.x, height = size.y; - - // Set reasonable values for position and size if defaults have - // been requested - // - // MB TODO: something better than these arbitrary values ? + + // Set reasonable values for position and size if defaults have been + // requested // - if ( width == -1 ) width = 400; - if ( height = -1 ) height = 400; + // MB TODO: something better than these arbitrary values ? + // VZ should use X resources for this... + if ( width == -1 ) + width = 400; + if ( height == -1 ) + height = 400; int displayW, displayH; wxDisplaySize( &displayW, &displayH ); @@ -166,9 +168,9 @@ bool wxFrame::Create(wxWindow *parent, if ( y == -1 ) { y = (displayH - height) / 2; - if (y < 10) y = 10; + if (y < 10) y = 10; } - + if (wxTopLevelUsed) { // Change suggested by Matthew Flatt @@ -323,7 +325,7 @@ bool wxFrame::Create(wxWindow *parent, wxFrame::~wxFrame() { m_isBeingDeleted = TRUE; - + if (m_clientArea) XtRemoveEventHandler((Widget) m_clientArea, ExposureMask, FALSE, wxUniversalRepaintProc, (XtPointer) this);