From 36ca96bcfe7b35a908e8e880cce615125f4fb811 Mon Sep 17 00:00:00 2001 From: mahlemiut Date: Fri, 3 Jun 2016 19:13:08 +1200 Subject: debugimgui: pressing Enter on an empty console input box does a single step. --- src/osd/modules/debugger/debugimgui.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/osd/modules/debugger/debugimgui.cpp') diff --git a/src/osd/modules/debugger/debugimgui.cpp b/src/osd/modules/debugger/debugimgui.cpp index 199a4f72b87..4e6ad5bd653 100644 --- a/src/osd/modules/debugger/debugimgui.cpp +++ b/src/osd/modules/debugger/debugimgui.cpp @@ -437,8 +437,14 @@ void debug_imgui::handle_console(running_machine* machine) { if(view_main_console->exec_cmd && view_main_console->type == DVT_CONSOLE) { - if(strlen(view_main_console->console_input) > 0) - debug_console_execute_command(*m_machine, view_main_console->console_input, 1); + // if console input is empty, then do a single step + if(strlen(view_main_console->console_input) == 0) + { + debug_cpu_get_visible_cpu(*m_machine)->debug()->single_step(); + view_main_console->exec_cmd = false; + return; + } + debug_console_execute_command(*m_machine, view_main_console->console_input, 1); // check for commands that start execution (so that input fields can be disabled) if(strcmp(view_main_console->console_input,"g") == 0) m_running = true; -- cgit v1.2.3