X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a46935cb544043417c6b44ac246ec9c0cbeebf69..df02852424b38b483c4c072eb1df6ac35825153c:/src/mgl/window.cpp diff --git a/src/mgl/window.cpp b/src/mgl/window.cpp index 55dfa75291..b79394efbc 100644 --- a/src/mgl/window.cpp +++ b/src/mgl/window.cpp @@ -117,7 +117,6 @@ bool wxCreateMGL_WM() #if wxUSE_SYSTEM_OPTIONS // FIXME_MGL -- so what is The Proper Way? - width=800, height=600; if ( wxSystemOptions::HasOption(wxT("mgl.screen-width") ) width = wxSystemOptions::GetOptionInt(wxT("mgl.screen-width")); if ( wxSystemOptions::HasOption(wxT("mgl.screen-height") ) @@ -199,7 +198,13 @@ static ibool wxWindowMouseHandler(window_t *wnd, event_t *e) MGL_wmCoordGlobalToLocal(win->GetHandle(), e->where_x, e->where_y, &where.x, &where.y); - if ( !win->IsEnabled() ) return FALSE; + for (wxWindowMGL *w = win; w; w = w->GetParent()) + { + if ( !w->IsEnabled() ) + return FALSE; + if ( w->IsTopLevel() ) + break; + } wxEventType type = wxEVT_NULL; wxMouseEvent event; @@ -1098,6 +1103,12 @@ void wxWindowMGL::HandlePaint(MGLDevCtx *dc) return; } +#if 0 // FIXME_MGL -- debugging stuff! + dc->setColorRGB(255,0,255); + dc->fillRect(-1000,-1000,2000,2000); + wxUsleep(100); +#endif + MGLRegion clip; dc->getClipRegion(clip); m_updateRegion = wxRegion(clip);