X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/5c68088294f06c857b2226100fd14956f03abc01..c9d13e86a698164843715665624ccb929e37255c:/src/univ/toolbar.cpp?ds=sidebyside diff --git a/src/univ/toolbar.cpp b/src/univ/toolbar.cpp index 41dc5d2281..9b36cc74ac 100644 --- a/src/univ/toolbar.cpp +++ b/src/univ/toolbar.cpp @@ -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(); } }