]> git.saurik.com Git - wxWidgets.git/blobdiff - src/univ/toolbar.cpp
move SendSizeEvent() down to wxWindow from wxFrame; added SendSizeEventToParent(...
[wxWidgets.git] / src / univ / toolbar.cpp
index 41dc5d22813557a9012a4c98c65da2cc82e2aa72..9b36cc74ac75e1494c520c32705f21615e3af164 100644 (file)
@@ -587,13 +587,7 @@ void wxToolBar::DoSetSize(int x, int y, int width, int height, int sizeFlags)
     // otherwise the toolbar can be shown incorrectly
     if ( old_width != width || old_height != height )
     {
-        // But before we send the size event check it
-        // we have a frame that is not being deleted.
-        wxFrame *frame = wxDynamicCast(GetParent(), wxFrame);
-        if ( frame && !frame->IsBeingDeleted() )
-        {
-            frame->SendSizeEvent();
-        }
+        SendSizeEventToParent();
     }
 }