]> git.saurik.com Git - wxWidgets.git/commitdiff
Toplevel windows don't have sibling static boxes. Fixes crash in AdjustStaticBoxZOrder.
authorJamie Gadd <jrgadd2@cs.latrobe.edu.au>
Fri, 10 Feb 2006 21:44:54 +0000 (21:44 +0000)
committerJamie Gadd <jrgadd2@cs.latrobe.edu.au>
Fri, 10 Feb 2006 21:44:54 +0000 (21:44 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37475 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/window.cpp

index ee37aeb2c73f808b2d53c05738d8ed51551157f5..5273cbc4d6b365330204e2aecec76600938340a9 100644 (file)
@@ -1428,6 +1428,10 @@ void wxWindowMSW::Update()
 // a drop target
 static inline void AdjustStaticBoxZOrder(wxWindow *parent)
 {
+    // no sibling static boxes if we have no parent (ie TLW)
+    if ( !parent )
+        return;
+
     for ( wxWindowList::compatibility_iterator node = parent->GetChildren().GetFirst();
           node;
           node = node->GetNext() )