]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/menucmn.cpp
fixes for harmless mingw32 warnings
[wxWidgets.git] / src / common / menucmn.cpp
index 8ab7f2b95f5af9a7a396881c7c3f08db4620f400..45ad387456d163e61e54b5d37684dc4738179c97 100644 (file)
@@ -385,6 +385,8 @@ wxMenuItem *wxMenuBase::DoRemove(wxMenuItem *item)
     if ( submenu )
     {
         submenu->SetParent((wxMenu *)NULL);
+        if ( submenu->IsAttached() )
+            submenu->Detach();
     }
 
     return item;