Skip to content

Commit

Permalink
Patched to compile on Mac OS X (not that you should necessarily be us…
Browse files Browse the repository at this point in the history
…ing this

 on Mac OS X, but still) ...
  • Loading branch information
icculus committed Jun 3, 2007
1 parent 2864daf commit 96f65b7
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/video/maccommon/SDL_macevents.c
Expand Up @@ -159,6 +159,8 @@ static int Mac_HandleEvents(_THIS, int wait4it)
/* Check the current state of the keyboard */
if ( SDL_GetAppState() & SDL_APPINPUTFOCUS ) {
KeyMap keys;
const Uint8 *keysptr = (Uint8 *) &keys;
const Uint8 *last_keysptr = (Uint8 *) &last_keys;

/* Check for special non-event keys */
if ( event.modifiers != last_mods ) {
Expand Down Expand Up @@ -214,8 +216,10 @@ static int Mac_HandleEvents(_THIS, int wait4it)
is immediately followed by a keyup event.
*/
GetKeys(keys);
if ( (keys[0] != last_keys[0]) || (keys[1] != last_keys[1]) ||
(keys[2] != last_keys[2]) || (keys[3] != last_keys[3]) ) {
if ( (keysptr[0] != last_keysptr[0]) ||
(keysptr[1] != last_keysptr[1]) ||
(keysptr[2] != last_keysptr[2]) ||
(keysptr[3] != last_keysptr[3]) ) {
SDL_keysym keysym;
int old_bit, new_bit;

Expand Down Expand Up @@ -730,7 +734,7 @@ static void Mac_DoAppleMenu(_THIS, long choice)

#if !TARGET_API_MAC_CARBON
/* Since we don't initialize QuickDraw, we need to get a pointer to qd */
QDGlobals *theQD = NULL;
struct QDGlobals *theQD = NULL;
#endif

/* Exported to the macmain code */
Expand Down

0 comments on commit 96f65b7

Please sign in to comment.