fix arrow-key navigation of menus in Mac OS X 10.5
svn: r7728
This commit is contained in:
parent
f085196bf8
commit
8b0e48d7aa
|
@ -51,6 +51,8 @@ int wxTranslateRawKey(int key);
|
|||
|
||||
int wxMenuBarHeight;
|
||||
|
||||
extern int wx_leave_all_input_alone;
|
||||
|
||||
extern wxApp *wxTheApp;
|
||||
//-----------------------------------------------------------------------------
|
||||
wxApp::wxApp():wxbApp()
|
||||
|
@ -369,7 +371,9 @@ void wxApp::doMacMouseDown(void)
|
|||
|
||||
wxTracking();
|
||||
wxPrepareMenuDraw();
|
||||
wx_leave_all_input_alone++;
|
||||
menuResult = MenuSelect(cCurrentEvent.where);
|
||||
--wx_leave_all_input_alone;
|
||||
wxDoneMenuDraw(!!menuResult);
|
||||
doMacInMenuBar(menuResult, FALSE);
|
||||
}
|
||||
|
@ -1437,8 +1441,6 @@ void wxApp::DoDefaultAboutItem(void)
|
|||
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
extern int wx_leave_all_input_alone;
|
||||
|
||||
void wxPrimDialogSetUp()
|
||||
{
|
||||
wxUnhideCursor();
|
||||
|
|
|
@ -41,6 +41,8 @@
|
|||
#define PAD_X 2
|
||||
#define MSPACEY 1
|
||||
|
||||
extern int wx_leave_all_input_alone;
|
||||
|
||||
static char *protect_leading_hyphen(char *s)
|
||||
{
|
||||
if (s[0] == '-') {
|
||||
|
@ -316,7 +318,9 @@ void wxChoice::OnEvent(wxMouseEvent *event) // mac platform only
|
|||
startPt.h = startH - PAD_Y;
|
||||
|
||||
wxTracking();
|
||||
wx_leave_all_input_alone++;
|
||||
trackResult = TrackControl(cMacControl,startPt,(ControlActionUPP)-1);
|
||||
--wx_leave_all_input_alone;
|
||||
if (trackResult) {
|
||||
wxCommandEvent *commandEvent;
|
||||
selection = GetControlValue(cMacControl);
|
||||
|
|
|
@ -34,6 +34,8 @@
|
|||
int SetOriginX = 0;
|
||||
int SetOriginY = 0;
|
||||
|
||||
extern int wx_leave_all_input_alone;
|
||||
|
||||
/* The gMouseWindow declaration confises xform.ss. */
|
||||
#ifdef MZ_PRECISE_GC
|
||||
START_XFORM_SKIP;
|
||||
|
@ -2092,7 +2094,9 @@ Bool wxWindow::PopupMenu(wxMenu *menu, double x, double y)
|
|||
pos.h = (short)x + SetOriginX;
|
||||
LocalToGlobal(&pos);
|
||||
wxTracking();
|
||||
wx_leave_all_input_alone++;
|
||||
sel = ::PopUpMenuSelect(m, pos.v, pos.h, 0);
|
||||
--wx_leave_all_input_alone;
|
||||
|
||||
ReleaseCurrentDC();
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user