From: Václav Slavík <vslavik@fastmail.fm> Date: Sun, 14 Oct 2001 22:20:24 +0000 (+0000) Subject: wxWindow::Enable now correctly has recursive effect (and maybe other fixes) X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/0a89ac9c270bd792d36d3d08d156b69b101cf3dd wxWindow::Enable now correctly has recursive effect (and maybe other fixes) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12001 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/mgl/window.cpp b/src/mgl/window.cpp index d03dfa66bd..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;