ui/selmenu.cpp: Fixed issue with focus rotation when filter matches no items.
This commit is contained in:
parent
9292def5fa
commit
2c96db827d
@ -958,12 +958,12 @@ void menu_select_launch::rotate_focus(int dir)
|
||||
case focused_menu::MAIN:
|
||||
if (selected_index() >= m_available_items)
|
||||
{
|
||||
if ((0 > dir) || (m_panels_status == HIDE_BOTH))
|
||||
if ((m_panels_status == HIDE_BOTH) || ((0 > dir) && m_available_items))
|
||||
select_prev();
|
||||
else if (m_panels_status == HIDE_LEFT_PANEL)
|
||||
set_focus(focused_menu::RIGHTTOP);
|
||||
else if (0 > dir)
|
||||
set_focus((m_panels_status == HIDE_RIGHT_PANEL) ? focused_menu::LEFT : focused_menu::RIGHTBOTTOM);
|
||||
else
|
||||
set_focus(focused_menu::LEFT);
|
||||
set_focus((m_panels_status == HIDE_LEFT_PANEL) ? focused_menu::RIGHTTOP : focused_menu::LEFT);
|
||||
}
|
||||
else if (m_skip_main_items || (m_panels_status != HIDE_BOTH))
|
||||
{
|
||||
|
@ -314,7 +314,8 @@ private:
|
||||
{
|
||||
if (!m_prev_selected)
|
||||
{
|
||||
set_selected_index(0);
|
||||
if (m_available_items)
|
||||
set_selected_index(0);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -1198,8 +1198,8 @@ LRESULT CALLBACK win_window_info::video_window_proc(HWND wnd, UINT message, WPAR
|
||||
// TODO: other pointer events?
|
||||
//case WM_POINTERACTIVATE:
|
||||
//case WM_POINTERDEVICECHANGE:
|
||||
//case WM_POINTERDEVICECINRANGE:
|
||||
//case WM_POINTERDEVICECOUTOFRANGE:
|
||||
//case WM_POINTERDEVICEINRANGE:
|
||||
//case WM_POINTERDEVICEOUTOFRANGE:
|
||||
//case WM_POINTERROUTEDAWAY:
|
||||
//case WM_POINTERROUTEDRELEASED:
|
||||
//case WM_POINTERROUTEDTO:
|
||||
|
Loading…
Reference in New Issue
Block a user