summaryrefslogtreecommitdiffstatshomepage
path: root/src/frontend
diff options
context:
space:
mode:
authorGravatarGravatar Vas Crabb <vas@vastheman.com>2019-11-18 21:36:47 +1100
committerGravatarGravatar Vas Crabb <vas@vastheman.com>2019-11-18 21:36:47 +1100
commit5e8dad836af986d5784a6f2a04eb0c7329651afa (patch)
treec2636ae319465dc9c6a335b62a5e20e781ec83f7 /src/frontend
parentbc4906f99155d58ad7b0f5e896e00dcf21bc9d45 (diff)
UI: if panel is collapsed while focused, return focus to systems/software
Diffstat (limited to 'src/frontend')
-rw-r--r--src/frontend/mame/ui/selmenu.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/frontend/mame/ui/selmenu.cpp b/src/frontend/mame/ui/selmenu.cpp
index 823412314ae..f150a06dc8e 100644
--- a/src/frontend/mame/ui/selmenu.cpp
+++ b/src/frontend/mame/ui/selmenu.cpp
@@ -1637,6 +1637,12 @@ void menu_select_launch::handle_events(uint32_t flags, event &ev)
m_topline_datsview -= m_right_visible_lines - 1;
else if (hover() == HOVER_LPANEL_ARROW)
{
+ if (get_focus() == focused_menu::LEFT)
+ {
+ set_focus(focused_menu::MAIN);
+ select_prev();
+ }
+
if (ui_globals::panels_status == HIDE_LEFT_PANEL)
ui_globals::panels_status = SHOW_PANELS;
else if (ui_globals::panels_status == HIDE_BOTH)
@@ -1648,6 +1654,12 @@ void menu_select_launch::handle_events(uint32_t flags, event &ev)
}
else if (hover() == HOVER_RPANEL_ARROW)
{
+ if ((get_focus() == focused_menu::RIGHTTOP) || (get_focus() == focused_menu::RIGHTBOTTOM))
+ {
+ set_focus(focused_menu::MAIN);
+ select_prev();
+ }
+
if (ui_globals::panels_status == HIDE_RIGHT_PANEL)
ui_globals::panels_status = SHOW_PANELS;
else if (ui_globals::panels_status == HIDE_BOTH)