equal
deleted
inserted
replaced
319 } else { |
319 } else { |
320 int posx, posy; |
320 int posx, posy; |
321 |
321 |
322 /* Give mouse position relative to window position */ |
322 /* Give mouse position relative to window position */ |
323 posx = mx - x2; |
323 posx = mx - x2; |
324 if (posx<0) posx = x2; |
324 if (posx<0) posx = 0; |
325 if (posx>w2) posx = w2-1; |
325 if (posx>w2) posx = w2-1; |
326 posy = my - y2; |
326 posy = my - y2; |
327 if (posy<0) posy = y2; |
327 if (posy<0) posy = 0; |
328 if (posy>h2) posy = h2-1; |
328 if (posy>h2) posy = h2-1; |
329 |
329 |
330 SDL_PrivateMouseMotion(0, 0, posx, posy); |
330 SDL_PrivateMouseMotion(0, 0, posx, posy); |
331 } |
331 } |
332 prevmousex = mx; |
332 prevmousex = mx; |