]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mgl/window.cpp
rename g_openDialogs to wxOpenModalDialogsCount and define it in toplevel.cpp to...
[wxWidgets.git] / src / mgl / window.cpp
index 70a9ffaf6431198e81ef573bff178f34d7e1e866..082e7dc7c8b0a5eec3bd1b09215c2ff6b546f288 100644 (file)
@@ -184,7 +184,7 @@ static ibool MGLAPI wxWindowMouseHandler(window_t *wnd, event_t *e)
     {
         case EVT_MOUSEDOWN:
             // Change focus if the user clicks outside focused window:
-            if ( win->AcceptsFocus() && wxWindow::FindFocus() != win )
+            if ( win->CanAcceptFocus() && wxWindow::FindFocus() != win )
                 win->SetFocus();
 
             if ( e->message & EVT_DBLCLICK )
@@ -1099,14 +1099,6 @@ void wxWindowMGL::GetTextExtent(const wxString& string,
 // painting
 // ---------------------------------------------------------------------------
 
-void wxWindowMGL::Clear()
-{
-    wxClientDC dc((wxWindow *)this);
-    wxBrush brush(GetBackgroundColour(), wxSOLID);
-    dc.SetBackground(brush);
-    dc.Clear();
-}
-
 void wxWindowMGL::Refresh(bool eraseBack, const wxRect *rect)
 {
     if ( m_eraseBackground == -1 )
@@ -1225,6 +1217,6 @@ wxWindow* wxFindWindowAtPoint(const wxPoint& pt)
 
 void wxWindowMGL::OnInternalIdle()
 {
-    if (wxUpdateUIEvent::CanUpdate(this))
+    if (wxUpdateUIEvent::CanUpdate(this) && IsShown())
         UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
 }