]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/app.cpp
Fixed wxPalette memory leak when loading BMP files
[wxWidgets.git] / src / msw / app.cpp
index 82851e6f1392e52f0620d3e378de7aa6c1e98d83..71d518c4e772e4541189d045fce885bc04270927 100644 (file)
@@ -1016,14 +1016,14 @@ void wxApp::OnIdle(wxIdleEvent& event)
 bool wxApp::SendIdleEvents()
 {
     bool needMore = FALSE;
-    wxNode* node = wxTopLevelWindows.First();
+
+    wxWindowList::Node* node = wxTopLevelWindows.GetFirst();
     while (node)
     {
-        wxWindow* win = (wxWindow*) node->Data();
+        wxWindow* win = node->GetData();
         if (SendIdleEvents(win))
             needMore = TRUE;
-
-        node = node->Next();
+        node = node->GetNext();
     }
 
     return needMore;
@@ -1097,8 +1097,8 @@ wxWindow* wxApp::GetTopWindow() const
 {
     if (m_topWindow)
         return m_topWindow;
-    else if (wxTopLevelWindows.Number() > 0)
-        return (wxWindow*) wxTopLevelWindows.First()->Data();
+    else if (wxTopLevelWindows.GetCount() > 0)
+        return wxTopLevelWindows.GetFirst()->GetData();
     else
         return NULL;
 }