]> git.saurik.com Git - wxWidgets.git/blobdiff - src/univ/winuniv.cpp
moved some more stuff from .cpp files to here
[wxWidgets.git] / src / univ / winuniv.cpp
index a3e50aa7dd554887408b372db4a4bfb2ae64903e..f4aeb43620bce7d755844fc36904fba567afc982 100644 (file)
@@ -393,13 +393,13 @@ void wxWindow::Refresh(bool eraseBackground, const wxRect *rectClient)
     wxWindowNative::Refresh(eraseBackground, &rectWin);
 
     // Refresh all sub controls if any.
-    wxWindowList::Node *node = GetChildren().GetFirst();
+    wxWindowList::compatibility_iterator node = GetChildren().GetFirst();
     while ( node )
     {
         wxWindow *win = node->GetData();
         // Only refresh sub controls when it is visible 
         // and when it is in the update region.
-        if(win->IsShown() && wxRegion(rectWin).Contains(win->GetRect()) != wxOutRegion)
+        if(!win->IsKindOf(CLASSINFO(wxTopLevelWindow)) && win->IsShown() && wxRegion(rectWin).Contains(win->GetRect()) != wxOutRegion)
             win->Refresh(eraseBackground, &rectWin);
             
         node = node->GetNext();
@@ -954,7 +954,7 @@ void wxWindow::ScrollWindow(int dx, int dy, const wxRect *rect)
     // scroll children accordingly:
     wxPoint offset(dx, dy);
 
-    for (wxWindowList::Node *node = GetChildren().GetFirst();
+    for (wxWindowList::compatibility_iterator node = GetChildren().GetFirst();
          node; node = node->GetNext())
     {
         wxWindow *child = node->GetData();