mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 12:32:52 +00:00
Create video_driver_get_video_output_next/video_driver_get_video_output_prev
This commit is contained in:
parent
efdbd03433
commit
2392a433d8
@ -846,3 +846,37 @@ void video_driver_apply_state_changes(void)
|
||||
return;
|
||||
driver->video_poke->apply_state_changes(driver->video_data);
|
||||
}
|
||||
|
||||
void video_driver_get_video_output_next(void)
|
||||
{
|
||||
driver_t *driver = driver_get_ptr();
|
||||
|
||||
if (!driver)
|
||||
return;
|
||||
if (!driver->video)
|
||||
return;
|
||||
if (!driver->video_data)
|
||||
return;
|
||||
if (!driver->video_poke)
|
||||
return;
|
||||
if (!driver->video_poke->get_video_output_next)
|
||||
return;
|
||||
driver->video_poke->get_video_output_next(driver->video_data);
|
||||
}
|
||||
|
||||
void video_driver_get_video_output_prev(void)
|
||||
{
|
||||
driver_t *driver = driver_get_ptr();
|
||||
|
||||
if (!driver)
|
||||
return;
|
||||
if (!driver->video)
|
||||
return;
|
||||
if (!driver->video_data)
|
||||
return;
|
||||
if (!driver->video_poke)
|
||||
return;
|
||||
if (!driver->video_poke->get_video_output_prev)
|
||||
return;
|
||||
driver->video_poke->get_video_output_prev(driver->video_data);
|
||||
}
|
||||
|
@ -314,6 +314,10 @@ void video_driver_set_filtering(unsigned index, bool smooth);
|
||||
|
||||
void video_driver_apply_state_changes(void);
|
||||
|
||||
void video_driver_get_video_output_next(void);
|
||||
|
||||
void video_driver_get_video_output_prev(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
@ -442,18 +442,10 @@ static int action_toggle_video_resolution(unsigned type, const char *label,
|
||||
switch (action)
|
||||
{
|
||||
case MENU_ACTION_LEFT:
|
||||
if (driver->video_data && driver->video_poke &&
|
||||
driver->video_poke->get_video_output_prev)
|
||||
{
|
||||
driver->video_poke->get_video_output_prev(driver->video_data);
|
||||
}
|
||||
video_driver_get_video_output_prev();
|
||||
break;
|
||||
case MENU_ACTION_RIGHT:
|
||||
if (driver->video_data && driver->video_poke &&
|
||||
driver->video_poke->get_video_output_next)
|
||||
{
|
||||
driver->video_poke->get_video_output_next(driver->video_data);
|
||||
}
|
||||
video_driver_get_video_output_next();
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user