mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 21:32:45 +00:00
Go through menu_input_pointer_state more
This commit is contained in:
parent
fb67a39d32
commit
670350dc1f
@ -233,12 +233,14 @@ static void glui_render(void)
|
||||
|
||||
if (settings->menu.pointer.enable)
|
||||
{
|
||||
menu_input->pointer.ptr =
|
||||
(menu_input->pointer.y - glui->line_height + menu->scroll_y - 16)
|
||||
int16_t pointer_y = menu_input_pointer_state(MENU_POINTER_Y_AXIS);
|
||||
|
||||
menu_input->pointer.ptr =
|
||||
(pointer_y - glui->line_height + menu->scroll_y - 16)
|
||||
/ glui->line_height;
|
||||
|
||||
menu->scroll_y -= menu_input->pointer.accel / 60.0;
|
||||
menu_input->pointer.accel = menu_input->pointer.accel * 0.96;
|
||||
menu->scroll_y -= menu_input->pointer.accel / 60.0;
|
||||
menu_input->pointer.accel = menu_input->pointer.accel * 0.96;
|
||||
}
|
||||
|
||||
if (settings->menu.mouse.enable)
|
||||
|
@ -1433,12 +1433,13 @@ static void xmb_render(void)
|
||||
{
|
||||
for (i = 0; i < end; i++)
|
||||
{
|
||||
float item_y1 = xmb->margins.screen.top + xmb_item_y(xmb, i, current);
|
||||
float item_y2 = item_y1 + xmb->icon.size;
|
||||
float item_y1 = xmb->margins.screen.top + xmb_item_y(xmb, i, current);
|
||||
float item_y2 = item_y1 + xmb->icon.size;
|
||||
int16_t pointer_y = menu_input_pointer_state(MENU_POINTER_Y_AXIS);
|
||||
|
||||
if (settings->menu.pointer.enable)
|
||||
{
|
||||
if (menu_input->pointer.y > item_y1 && menu_input->pointer.y < item_y2)
|
||||
if (pointer_y > item_y1 && pointer_y < item_y2)
|
||||
menu_input->pointer.ptr = i;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user