generate command events for accelerators even when there is no menu bar (#9784) fixing the bug introduced in r54510
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@56069 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -101,6 +101,10 @@ All (Unix):
|
|||||||
- Return false from wxSingleInstanceChecker::IsAnotherRunning() if an error
|
- Return false from wxSingleInstanceChecker::IsAnotherRunning() if an error
|
||||||
occurred while opening or reading the lock file (Lauri Nurmi).
|
occurred while opening or reading the lock file (Lauri Nurmi).
|
||||||
|
|
||||||
|
wxMSW:
|
||||||
|
|
||||||
|
- Restored generation of events for accelerators when there is no menu bar.
|
||||||
|
|
||||||
wxGTK:
|
wxGTK:
|
||||||
|
|
||||||
- Fixed printing to use fonts sizes adjustment consistent with wxMSW.
|
- Fixed printing to use fonts sizes adjustment consistent with wxMSW.
|
||||||
|
@@ -954,34 +954,20 @@ bool wxFrame::HandleCommand(WXWORD id, WXWORD cmd, WXHWND control)
|
|||||||
return win->MSWCommand(cmd, id);
|
return win->MSWCommand(cmd, id);
|
||||||
}
|
}
|
||||||
|
|
||||||
// handle here commands from menus and accelerators
|
// handle here commands from menus and accelerators for our menu bar items,
|
||||||
if ( cmd == 0 || cmd == 1 )
|
// all the rest is handled by wxWindow itself
|
||||||
|
if ( !control && (cmd == 0 /* menu */ || cmd == 1 /* accel */) )
|
||||||
{
|
{
|
||||||
#if wxUSE_MENUS_NATIVE
|
#if wxUSE_MENUS_NATIVE
|
||||||
if ( wxCurrentPopupMenu )
|
if ( !wxCurrentPopupMenu )
|
||||||
{
|
|
||||||
wxMenu *popupMenu = wxCurrentPopupMenu;
|
|
||||||
wxCurrentPopupMenu = NULL;
|
|
||||||
|
|
||||||
return popupMenu->MSWCommand(cmd, id);
|
|
||||||
}
|
|
||||||
#endif // wxUSE_MENUS_NATIVE
|
#endif // wxUSE_MENUS_NATIVE
|
||||||
|
|
||||||
#if defined(__SMARTPHONE__) && defined(__WXWINCE__)
|
|
||||||
// handle here commands from Smartphone menu bar
|
|
||||||
if ( wxTopLevelWindow::HandleCommand(id, cmd, control ) )
|
|
||||||
{
|
{
|
||||||
return true;
|
if ( GetMenuBar() && ProcessCommand(id) )
|
||||||
}
|
return true;
|
||||||
#endif // __SMARTPHONE__ && __WXWINCE__
|
|
||||||
|
|
||||||
if ( ProcessCommand(id) )
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return false;
|
return wxFrameBase::HandleCommand(id, cmd, control);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool wxFrame::HandleMenuSelect(WXWORD nItem, WXWORD flags, WXHMENU hMenu)
|
bool wxFrame::HandleMenuSelect(WXWORD nItem, WXWORD flags, WXHMENU hMenu)
|
||||||
|
Reference in New Issue
Block a user