Gerbview: bug fix: crash when changing selected language

This commit is contained in:
jean-pierre charras 2011-04-23 20:35:40 +02:00
parent c89070da83
commit 4dee08c318
1 changed files with 3 additions and 3 deletions

View File

@ -72,9 +72,9 @@ void GERBVIEW_FRAME::ReCreateMenuBar( void )
// Recent drill files // Recent drill files
static wxMenu* openRecentDrlMenu; static wxMenu* openRecentDrlMenu;
if( openRecentDrlMenu ) if( openRecentDrlMenu )
wxGetApp().m_fileHistory.RemoveMenu( openRecentDrlMenu ); m_drillFileHistory.RemoveMenu( openRecentDrlMenu );
openRecentDrlMenu = new wxMenu(); openRecentDrlMenu = new wxMenu();
wxGetApp().m_fileHistory.UseMenu( openRecentDrlMenu ); m_drillFileHistory.UseMenu( openRecentDrlMenu );
m_drillFileHistory.AddFilesToMenu( ); m_drillFileHistory.AddFilesToMenu( );
ADD_MENUITEM_WITH_HELP_AND_SUBMENU( fileMenu, openRecentDrlMenu, ADD_MENUITEM_WITH_HELP_AND_SUBMENU( fileMenu, openRecentDrlMenu,
wxID_ANY, wxID_ANY,