From: Stefan Csomor Date: Mon, 28 Feb 2005 06:14:32 +0000 (+0000) Subject: cleanup X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/025357ca4feb7a7f4cfdc85cd1ff3c37b300c2b1 cleanup git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32450 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/mac/carbon/menu.cpp b/src/mac/carbon/menu.cpp index 71701a0a04..69824cf291 100644 --- a/src/mac/carbon/menu.cpp +++ b/src/mac/carbon/menu.cpp @@ -568,6 +568,19 @@ auto-merge for MDI in case this will be necessary */ +const wxMenuInfoList& wxMenuBar::GetMenuInfos() const +{ + wxMenuInfoList* list = const_cast< wxMenuInfoList* >( &m_menuInfos ) ; + WX_CLEAR_LIST( wxMenuInfoList , *list ) ; + for( size_t i = 0 ; i < GetMenuCount() ; ++i ) + { + wxMenuInfo* info = new wxMenuInfo() ; + info->Create( const_cast(this)->GetMenu(i) , GetLabelTop(i) ) ; + list->Append( info ) ; + } + return m_menuInfos ; +} + wxMenuBar* wxMenuBar::s_macInstalledMenuBar = NULL ; wxMenuBar* wxMenuBar::s_macCommonMenuBar = NULL ; @@ -808,10 +821,6 @@ int wxMenuBar::FindMenu(const wxString& title) } -// --------------------------------------------------------------------------- -// wxMenuBar construction -// --------------------------------------------------------------------------- - // --------------------------------------------------------------------------- // wxMenuBar construction // ---------------------------------------------------------------------------