- wxAutoNSAutoreleasePool pool;
- bool ret = wxFrameBase::Show(show);
- if(show && GetMenuBar())
- [wxTheApp->GetNSApplication() setMenu:GetMenuBar()->GetNSMenu() ];
- return ret;
+ if ( menubar == GetMenuBar() )
+ {
+ // nothing to do
+ return;
+ }
+
+ wxFrameBase::DetachMenuBar();
+ wxFrameBase::AttachMenuBar(menubar);
+ wxMenuBarManager::GetInstance()->UpdateWindowMenuBar(this);