src/events/SDL_mouse.c
changeset 2727 76c2fc9696ea
parent 2725 6ce6d56b63bf
child 2765 f55c87ae336b
equal deleted inserted replaced
2726:f23ebf1ddac4 2727:76c2fc9696ea
   372 SDL_SendProximity(int id, int x, int y, int type)
   372 SDL_SendProximity(int id, int x, int y, int type)
   373 {
   373 {
   374     int index = SDL_GetMouseIndexId(id);
   374     int index = SDL_GetMouseIndexId(id);
   375     SDL_Mouse *mouse = SDL_GetMouse(index);
   375     SDL_Mouse *mouse = SDL_GetMouse(index);
   376     int posted = 0;
   376     int posted = 0;
       
   377 
       
   378     if (!mouse) {
       
   379         return 0;
       
   380     }
       
   381 
   377     last_x = x;
   382     last_x = x;
   378     last_y = y;
   383     last_y = y;
   379     if (SDL_ProcessEvents[type] == SDL_ENABLE) {
   384     if (SDL_ProcessEvents[type] == SDL_ENABLE) {
   380         SDL_Event event;
   385         SDL_Event event;
   381         event.proximity.which = (Uint8) index;
   386         event.proximity.which = (Uint8) index;