X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8d7ddd02649628327f8169cf2f4f9ee7b52f39c7..b916f809336755620b010293637b12763f01455d:/src/os2/menu.cpp diff --git a/src/os2/menu.cpp b/src/os2/menu.cpp index e960818b45..a964e5497a 100644 --- a/src/os2/menu.cpp +++ b/src/os2/menu.cpp @@ -73,7 +73,7 @@ static wxString TextToLabel(const wxString& rTitle) { wxString Title; const wxChar *pc; - for (pc = rTitle; *pc != wxT('\0'); pc++ ) + for (pc = rTitle.c_str(); *pc != wxT('\0'); pc++ ) { if (*pc == wxT('&') ) { @@ -85,10 +85,6 @@ static wxString TextToLabel(const wxString& rTitle) else Title << wxT('~'); } -// else if (*pc == wxT('/')) -// { -// Title << wxT('\\'); -// } else { if ( *pc == wxT('~') ) @@ -609,7 +605,12 @@ wxMenuItem* wxMenu::FindItem( } else if ( pItem->IsSubMenu() ) { - pItem = pItem->GetSubMenu()->FindItem(nItemId, hItem, ppItemMenu); + pItem = pItem->GetSubMenu()->FindItem( nItemId + ,hItem + ,ppItemMenu + ); + if (pItem) + break; } else { @@ -968,7 +969,6 @@ wxMenu* wxMenuBar::Remove( if (IsAttached()) { ::WinSendMsg((HWND)GetHmenu(), MM_REMOVEITEM, MPFROM2SHORT(nId, TRUE), (MPARAM)0); - pMenu->Detach(); #if wxUSE_ACCEL if (pMenu->HasAccels())