mirror of
https://git.wownero.com/wownero/wownero.git
synced 2024-08-15 01:03:23 +00:00
password: do not use line input on windows
This keeps its builtin command editing away Thanks iDunk for testing on Windows
This commit is contained in:
parent
c0bc6d96cd
commit
e1016bce14
1 changed files with 1 additions and 5 deletions
|
@ -57,7 +57,7 @@ namespace
|
||||||
|
|
||||||
DWORD mode_old;
|
DWORD mode_old;
|
||||||
::GetConsoleMode(h_cin, &mode_old);
|
::GetConsoleMode(h_cin, &mode_old);
|
||||||
DWORD mode_new = mode_old & ~(hide_input ? ENABLE_ECHO_INPUT : 0);
|
DWORD mode_new = mode_old & ~((hide_input ? ENABLE_ECHO_INPUT : 0) | ENABLE_LINE_INPUT);
|
||||||
::SetConsoleMode(h_cin, mode_new);
|
::SetConsoleMode(h_cin, mode_new);
|
||||||
|
|
||||||
bool r = true;
|
bool r = true;
|
||||||
|
@ -76,10 +76,6 @@ namespace
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
else if (ucs2_ch == L'\r')
|
else if (ucs2_ch == L'\r')
|
||||||
{
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
else if (ucs2_ch == L'\n')
|
|
||||||
{
|
{
|
||||||
std::cout << std::endl;
|
std::cout << std::endl;
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue