mirror of https://github.com/libsdl-org/SDL
This assert wasn't correct, we set the internal grab for mouse relative mode as well.
This commit is contained in:
parent
105f120615
commit
6aa1498b98
|
@ -2787,11 +2787,7 @@ SDL_SetWindowMouseGrab(SDL_Window * window, SDL_bool grabbed)
|
|||
SDL_bool
|
||||
SDL_GetWindowGrab(SDL_Window * window)
|
||||
{
|
||||
CHECK_WINDOW_MAGIC(window, SDL_FALSE);
|
||||
SDL_assert(!_this->grabbed_window ||
|
||||
((_this->grabbed_window->flags & SDL_WINDOW_MOUSE_GRABBED) != 0) ||
|
||||
((_this->grabbed_window->flags & SDL_WINDOW_KEYBOARD_GRABBED) != 0));
|
||||
return window == _this->grabbed_window;
|
||||
return (SDL_GetWindowKeyboardGrab(window) || SDL_GetWindowMouseGrab(window));
|
||||
}
|
||||
|
||||
SDL_bool
|
||||
|
|
Loading…
Reference in New Issue