From e4c187b718d6a80c00d379dd8671384ac099ca88 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Fri, 26 Jun 2020 16:57:54 +0200 Subject: [PATCH] xmb_render - Make it more similar to materialui_render --- menu/drivers/xmb.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/menu/drivers/xmb.c b/menu/drivers/xmb.c index 4ea4e5d0e7..6158f71710 100644 --- a/menu/drivers/xmb.c +++ b/menu/drivers/xmb.c @@ -3551,8 +3551,16 @@ static void xmb_render(void *data, false); } + /* This must be set every frame when using a pointer, + * otherwise touchscreen input breaks when changing + * orientation */ + gfx_display_set_width(width); + gfx_display_set_height(height); + + /* Read pointer state */ menu_input_get_pointer_state(&xmb->pointer); + if (xmb->pointer.type != MENU_POINTER_DISABLED) { size_t selection = menu_navigation_get_selection(); @@ -3562,12 +3570,6 @@ static void xmb_render(void *data, int16_t pointer_x = xmb->pointer.x; int16_t pointer_y = xmb->pointer.y; - /* This must be set every frame when using a pointer, - * otherwise touchscreen input breaks when changing - * orientation */ - gfx_display_set_width(width); - gfx_display_set_height(height); - /* When determining current pointer selection, we * only track pointer movements between the left * and right screen margins */ @@ -5027,9 +5029,8 @@ static void xmb_frame(void *data, video_frame_info_t *video_info) video_height); font_driver_flush(video_width, video_height, xmb->font); - font_driver_bind_block(xmb->font, NULL); - font_driver_flush(video_width, video_height, xmb->font2); + font_driver_bind_block(xmb->font, NULL); font_driver_bind_block(xmb->font2, NULL); /* Draw fullscreen thumbnails, if required */