src/video/cocoa/SDL_cocoamouse.m
changeset 6044 35448a5ea044
parent 5535 96594ac5fd1a
child 6138 4c64952a58fb
     1.1 --- a/src/video/cocoa/SDL_cocoamouse.m	Mon Oct 31 03:06:32 2011 -0400
     1.2 +++ b/src/video/cocoa/SDL_cocoamouse.m	Mon Oct 31 05:56:58 2011 -0400
     1.3 @@ -20,6 +20,8 @@
     1.4  */
     1.5  #include "SDL_config.h"
     1.6  
     1.7 +#if SDL_VIDEO_DRIVER_COCOA
     1.8 +
     1.9  #include "SDL_events.h"
    1.10  #include "SDL_cocoavideo.h"
    1.11  
    1.12 @@ -147,21 +149,6 @@
    1.13      SDL_SetDefaultCursor(Cocoa_CreateDefaultCursor());
    1.14  }
    1.15  
    1.16 -static int
    1.17 -ConvertMouseButtonToSDL(int button)
    1.18 -{
    1.19 -    switch (button)
    1.20 -    {
    1.21 -        case 0:
    1.22 -            return(SDL_BUTTON_LEFT);   /* 1 */
    1.23 -        case 1:
    1.24 -            return(SDL_BUTTON_RIGHT);  /* 3 */
    1.25 -        case 2:
    1.26 -            return(SDL_BUTTON_MIDDLE); /* 2 */
    1.27 -    }
    1.28 -    return button+1;
    1.29 -}
    1.30 -
    1.31  void
    1.32  Cocoa_HandleMouseEvent(_THIS, NSEvent *event)
    1.33  {
    1.34 @@ -202,4 +189,6 @@
    1.35  {
    1.36  }
    1.37  
    1.38 +#endif /* SDL_VIDEO_DRIVER_COCOA */
    1.39 +
    1.40  /* vi: set ts=4 sw=4 expandtab: */