mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-20 21:33:47 -07:00
chg: trigger colorsmode (proxspace) in direct calls to client
This commit is contained in:
parent
a5b406bffa
commit
c2df7ed824
1 changed files with 8 additions and 3 deletions
|
@ -641,7 +641,6 @@ finish2:
|
||||||
|
|
||||||
#if defined(_WIN32)
|
#if defined(_WIN32)
|
||||||
static bool DetectWindowsAnsiSupport(void) {
|
static bool DetectWindowsAnsiSupport(void) {
|
||||||
bool ret = false;
|
|
||||||
HKEY hKey = NULL;
|
HKEY hKey = NULL;
|
||||||
bool virtualTerminalLevelSet = false;
|
bool virtualTerminalLevelSet = false;
|
||||||
bool forceV2Set = false;
|
bool forceV2Set = false;
|
||||||
|
@ -681,9 +680,15 @@ static bool DetectWindowsAnsiSupport(void) {
|
||||||
}
|
}
|
||||||
RegCloseKey(hKey);
|
RegCloseKey(hKey);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
HANDLE hOut = GetStdHandle(STD_OUTPUT_HANDLE);
|
||||||
|
DWORD dwMode = 0;
|
||||||
|
GetConsoleMode(hOut, &dwMode);
|
||||||
|
dwMode |= ENABLE_VIRTUAL_TERMINAL_PROCESSING;
|
||||||
|
SetConsoleMode(hOut, dwMode);
|
||||||
|
|
||||||
// If both VirtualTerminalLevel and ForceV2 is set, AnsiColor should work
|
// If both VirtualTerminalLevel and ForceV2 is set, AnsiColor should work
|
||||||
ret = virtualTerminalLevelSet && forceV2Set;
|
return virtualTerminalLevelSet && forceV2Set;
|
||||||
return ret;
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue