src/events/SDL_mouse.c
changeset 2152 003c1b5b07da
parent 2049 5f6550e5184f
child 2710 44e49d3fa6cf
child 3760 64f346a83ed3
     1.1 --- a/src/events/SDL_mouse.c	Thu Jul 05 06:35:40 2007 +0000
     1.2 +++ b/src/events/SDL_mouse.c	Fri Jul 06 09:22:18 2007 +0000
     1.3 @@ -427,12 +427,12 @@
     1.4  }
     1.5  
     1.6  int
     1.7 -SDL_SendMouseWheel(int index, int motion)
     1.8 +SDL_SendMouseWheel(int index, int x, int y)
     1.9  {
    1.10      SDL_Mouse *mouse = SDL_GetMouse(index);
    1.11      int posted;
    1.12  
    1.13 -    if (!mouse || !motion) {
    1.14 +    if (!mouse || (!x && !y)) {
    1.15          return 0;
    1.16      }
    1.17  
    1.18 @@ -442,7 +442,8 @@
    1.19          SDL_Event event;
    1.20          event.type = SDL_MOUSEWHEEL;
    1.21          event.wheel.which = (Uint8) index;
    1.22 -        event.wheel.motion = motion;
    1.23 +        event.wheel.x = x;
    1.24 +        event.wheel.y = y;
    1.25          event.wheel.windowID = mouse->focus;
    1.26          posted = (SDL_PushEvent(&event) > 0);
    1.27      }