mirror of
https://github.com/libretro/RetroArch
synced 2025-03-29 22:20:21 +00:00
Add MENU_DISPLAY_CTL_RESTORE_CLEAR_COLOR
This commit is contained in:
parent
690c5c2bc8
commit
c3c408f9d6
@ -951,7 +951,7 @@ static void mui_frame(void *data)
|
||||
mui_draw_cursor(mui, &white_bg[0], mouse_x, mouse_y, width, height);
|
||||
}
|
||||
|
||||
menu_display_restore_clear_color();
|
||||
menu_display_ctl(MENU_DISPLAY_CTL_RESTORE_CLEAR_COLOR, NULL);
|
||||
menu_display_ctl(MENU_DISPLAY_CTL_UNSET_VIEWPORT, NULL);
|
||||
}
|
||||
|
||||
|
@ -443,6 +443,11 @@ bool menu_display_ctl(enum menu_display_ctl_state state, void *data)
|
||||
break;
|
||||
case MENU_DISPLAY_CTL_INIT_FIRST_DRIVER:
|
||||
return menu_display_driver_init_first(disp);
|
||||
case MENU_DISPLAY_CTL_RESTORE_CLEAR_COLOR:
|
||||
if (!menu_disp || !menu_disp->restore_clear_color)
|
||||
return false;
|
||||
menu_disp->restore_clear_color();
|
||||
break;
|
||||
case MENU_DISPLAY_CTL_NONE:
|
||||
default:
|
||||
break;
|
||||
@ -560,14 +565,6 @@ void menu_display_draw_bg(
|
||||
color2, vertex, tex_coord, vertex_count, prim_type);
|
||||
}
|
||||
|
||||
void menu_display_restore_clear_color(void)
|
||||
{
|
||||
menu_display_ctx_driver_t *menu_disp = menu_display_context_get_ptr();
|
||||
if (!menu_disp || !menu_disp->restore_clear_color)
|
||||
return;
|
||||
|
||||
menu_disp->restore_clear_color();
|
||||
}
|
||||
|
||||
void menu_display_clear_color(float r, float g, float b, float a)
|
||||
{
|
||||
|
@ -72,7 +72,8 @@ enum menu_display_ctl_state
|
||||
MENU_DISPLAY_CTL_FONT_MAIN_INIT,
|
||||
MENU_DISPLAY_CTL_FONT_BIND_BLOCK,
|
||||
MENU_DISPLAY_CTL_BLEND_BEGIN,
|
||||
MENU_DISPLAY_CTL_BLEND_END
|
||||
MENU_DISPLAY_CTL_BLEND_END,
|
||||
MENU_DISPLAY_CTL_RESTORE_CLEAR_COLOR
|
||||
};
|
||||
|
||||
enum menu_display_prim_type
|
||||
@ -172,8 +173,6 @@ void menu_display_matrix_4x4_rotate_z(
|
||||
unsigned menu_display_texture_load(void *data,
|
||||
enum texture_filter_type filter_type);
|
||||
|
||||
void menu_display_restore_clear_color(void);
|
||||
|
||||
void menu_display_clear_color(float r, float g, float b, float a);
|
||||
|
||||
void menu_display_texture_unload(uintptr_t *id);
|
||||
|
Loading…
x
Reference in New Issue
Block a user