src/events/SDL_mouse.c
changeset 7097 84bbd421d62f
parent 7089 257fc4e541e1
child 7104 4e4ca313000c
equal deleted inserted replaced
7096:640f553441e4 7097:84bbd421d62f
   163         }
   163         }
   164         return SDL_FALSE;
   164         return SDL_FALSE;
   165     }
   165     }
   166 
   166 
   167     if (window != mouse->focus) {
   167     if (window != mouse->focus) {
   168         mouse->last_x = x;
       
   169         mouse->last_y = y;
       
   170 
       
   171 #ifdef DEBUG_MOUSE
   168 #ifdef DEBUG_MOUSE
   172         printf("Mouse entered window, synthesizing focus gain event\n");
   169          printf("Mouse entered window, synthesizing focus gain & move event\n");
   173 #endif
   170 #endif
   174         SDL_SetMouseFocus(window);
   171          SDL_SetMouseFocus(window);
       
   172          SDL_PrivateSendMouseMotion(window, mouse->mouseID, 0, x, y);
   175     }
   173     }
   176     return SDL_TRUE;
   174     return SDL_TRUE;
   177 }
   175 }
   178 
   176 
   179 int
   177 int