// Is this menu on a menubar? (possibly nested)
wxFrame* frame = NULL;
- wxMenu* pm = menu;
- while ( pm && !frame )
- {
- if ( pm->IsAttached() )
- frame = pm->GetMenuBar()->GetFrame();
- pm = pm->GetParent();
- }
+ if(menu->IsAttached())
+ frame = menu->GetMenuBar()->GetFrame();
// FIXME: why do we have to call wxFrame::GetEventHandler() directly here?
// normally wxMenu::SendEvent() should be enough, if it doesn't work
for ( const wxChar *pc = text.c_str(); *pc; pc++ )
{
+ if ( *pc == wxT('\t'))
+ break;
+
if ( *pc == wxT('_') )
{
// GTK 1.2 escapes "xxx_xxx" to "xxx__xxx"