https://git.reactos.org/?p=reactos.git;a=commitdiff;h=2136409fdac17f3e91ea7…
commit 2136409fdac17f3e91ea736594d723d95c740d44
Author: Hermès Bélusca-Maïto <hermes.belusca-maito(a)reactos.org>
AuthorDate: Thu Jul 25 21:30:50 2024 +0200
Commit: Hermès Bélusca-Maïto <hermes.belusca-maito(a)reactos.org>
CommitDate: Fri Jul 26 22:58:02 2024 +0200
[USETUP] InstallDirectoryPage(): Pressing ESC erases the whole path line (#7185)
---
base/setup/usetup/usetup.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/base/setup/usetup/usetup.c b/base/setup/usetup/usetup.c
index 81187430563..f765ce6f180 100644
--- a/base/setup/usetup/usetup.c
+++ b/base/setup/usetup/usetup.c
@@ -3043,6 +3043,14 @@ InstallDirectoryPage(PINPUT_RECORD Ir)
CONSOLE_SetCursorXY(8 + Pos, 11);
}
}
+ else if (Ir->Event.KeyEvent.wVirtualKeyCode == VK_ESCAPE) /* ESC */
+ {
+ /* Erase the whole line */
+ *InstallDir = UNICODE_NULL;
+ Pos = Length = 0;
+ CONSOLE_SetInputTextXY(8, 11, 51, InstallDir);
+ CONSOLE_SetCursorXY(8 + Pos, 11);
+ }
else if (Ir->Event.KeyEvent.uChar.AsciiChar == 0x0D) /* ENTER */
{
CONSOLE_SetCursorType(TRUE, FALSE);