From b3e8407d7c8940979d9eaa4ce1000b0260dda875 Mon Sep 17 00:00:00 2001 From: Nathan Woods Date: Sun, 13 Apr 2014 12:47:01 +0000 Subject: [PATCH] I really got tired of looking at the text 'UI Select' and 'UI Cancel' in a blood red dialog, especially given how easy this was to fix --- src/emu/ui/ui.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/src/emu/ui/ui.c b/src/emu/ui/ui.c index 7ea8e39b2ee..72d027eeb61 100644 --- a/src/emu/ui/ui.c +++ b/src/emu/ui/ui.c @@ -1558,9 +1558,22 @@ void ui_manager::request_quit() UINT32 ui_manager::handler_confirm_quit(running_machine &machine, render_container *container, UINT32 state) { - astring quit_message("Are you sure you want to quit?\n\n"); - quit_message.cat("Press ''UI Select'' (default: Enter) to quit,\n"); - quit_message.cat("Press ''UI Cancel'' (default: Esc) to return to emulation."); + // get the text for 'UI Select' + astring ui_select_text; + machine.input().seq_name(ui_select_text, machine.ioport().type_seq(IPT_UI_SELECT, 0, SEQ_TYPE_STANDARD)); + + // get the text for 'UI Cancel' + astring ui_cancel_text; + machine.input().seq_name(ui_cancel_text, machine.ioport().type_seq(IPT_UI_CANCEL, 0, SEQ_TYPE_STANDARD)); + + // assemble the quit message + astring quit_message; + quit_message.printf( + "Are you sure you want to quit?\n\n" + "Press ''%s'' to quit,\n" + "Press ''%s'' to return to emulation.", + ui_select_text.cstr(), + ui_cancel_text.cstr()); machine.ui().draw_text_box(container, quit_message, JUSTIFY_CENTER, 0.5f, 0.5f, UI_RED_COLOR); machine.pause();