Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove SDL_SetWindowGrab for SDL3 #9339

Closed
cgutman opened this issue Mar 23, 2024 · 1 comment · Fixed by #9352
Closed

Remove SDL_SetWindowGrab for SDL3 #9339

cgutman opened this issue Mar 23, 2024 · 1 comment · Fixed by #9352

Comments

@cgutman
Copy link
Collaborator

cgutman commented Mar 23, 2024

We split SDL_SetWindowGrab() into SDL_SetWindowMouseGrab() and SDL_SetWindowKeyboardGrab() back in SDL 2.0.16 to provide a nicer interface than needing to mess around with SDL_HINT_GRAB_KEYBOARD to get keyboard grab (and having no way to grab the keyboard without also grabbing the mouse).

The corresponding window flag (SDL_WINDOW_INPUT_GRABBED) is already gone for SDL3, so I think we should also do away with the rest of the old grab interface (SDL_SetWindowGrab(), SDL_GetWindowGrab(), and SDL_HINT_GRAB_KEYBOARD) to force applications to be explicit about what type of grab they want.

@cgutman cgutman mentioned this issue Mar 23, 2024
1 task
@slouken
Copy link
Collaborator

slouken commented Mar 23, 2024

Sure, go ahead and create a PR for that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants