Synchronize Unlock and Blt with drawing loop, force loop to constant 60 FPS, fixes too fast scrolling (its still fast)
This commit is contained in:
parent
9606f1b54f
commit
b6f989eeee
5 changed files with 32 additions and 30 deletions
6
mouse.c
6
mouse.c
|
@ -87,7 +87,6 @@ void mouse_lock()
|
|||
ddraw->locked = TRUE;
|
||||
ClipCursor(&ddraw->cursorclip);
|
||||
while(ShowCursor(FALSE) > 0);
|
||||
SetEvent(ddraw_primary->flipEvent);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -107,11 +106,6 @@ void mouse_unlock()
|
|||
ClipCursor(NULL);
|
||||
ddraw->cursor.x = ddraw->width / 2;
|
||||
ddraw->cursor.y = ddraw->height / 2;
|
||||
|
||||
if(ddraw_primary)
|
||||
{
|
||||
SetEvent(ddraw_primary->flipEvent);
|
||||
}
|
||||
}
|
||||
|
||||
void mouse_init(HWND hWnd)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue