menubar activation, fixes #10352

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@57952 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor
2009-01-09 17:30:45 +00:00
parent 4d371eebfc
commit 80061353ef

View File

@@ -105,7 +105,9 @@ bool wxFrame::Enable(bool enable)
if ( !wxWindow::Enable(enable) )
return false;
if ( m_frameMenuBar && m_frameMenuBar == wxMenuBar::MacGetInstalledMenuBar() )
// we should always enable/disable the menubar, even if we are not current, otherwise
// we might miss some state change later (happened eg in the docview sample after PrintPreview)
if ( m_frameMenuBar /* && m_frameMenuBar == wxMenuBar::MacGetInstalledMenuBar() */ )
{
int iMaxMenu = m_frameMenuBar->GetMenuCount();
for ( int i = 0 ; i < iMaxMenu ; ++ i )