From 30c5e1fd67eaa2f8e7b22911f4ed96007581d3a7 Mon Sep 17 00:00:00 2001 From: d0k3 Date: Tue, 23 Feb 2021 16:10:10 +0100 Subject: [PATCH] Add firstrun instructions to software keyboard Adresses #601 --- arm9/source/common/swkbd.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/arm9/source/common/swkbd.c b/arm9/source/common/swkbd.c index 246c41c..484cd36 100644 --- a/arm9/source/common/swkbd.c +++ b/arm9/source/common/swkbd.c @@ -226,6 +226,13 @@ bool ShowKeyboard(char* inputstr, const u32 max_size, const char *format, ...) { TouchBox swkbd_numpad[32]; TouchBox* textbox = swkbd_alphabet; // always use this textbox + static bool show_instr = true; + static const char* instr = "Keyboard Controls:\n \n\x1B/\x1A - Move cursor\nR - Caps / Capslock\nX - Delete char\nY - Insert char\nA - Submit\nB - Cancel\n \nSELECT switches to\nclassic prompt"; + if (show_instr) { + ShowPrompt(false, instr); + show_instr = false; + } + // generate keyboards if (!BuildKeyboard(swkbd_alphabet, keys_alphabet, layout_alphabet)) return false; if (!BuildKeyboard(swkbd_special, keys_special, layout_special)) return false;