mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 21:32:45 +00:00
(sdl_input.c) Use video_driver_get_ident
This commit is contained in:
parent
4cccd6d596
commit
60fec26bcf
@ -299,15 +299,14 @@ static void sdl_grab_mouse(void *data, bool state)
|
||||
struct temp{
|
||||
SDL_Window *w;
|
||||
};
|
||||
sdl_input_t *sdl = (sdl_input_t*)data;
|
||||
driver_t *driver = driver_get_ptr();
|
||||
|
||||
if (driver->current_video != &video_sdl2)
|
||||
return;
|
||||
|
||||
/* First member of sdl2_video_t is the window */
|
||||
SDL_SetWindowGrab(((struct temp*)driver->video_data)->w,
|
||||
state ? SDL_TRUE : SDL_FALSE);
|
||||
if (!strcmp(video_driver_get_ident(), "sdl2"))
|
||||
{
|
||||
/* First member of sdl2_video_t is the window */
|
||||
SDL_SetWindowGrab(((struct temp*)driver->video_data)->w,
|
||||
state ? SDL_TRUE : SDL_FALSE);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user