mirror of
https://git.rip/DMCA_FUCKER/re3.git
synced 2024-12-23 07:40:01 +00:00
add -console cmdline arg instead of #if 0/1
# Conflicts: # src/skel/glfw/glfw.cpp # src/skel/win/win.cpp
This commit is contained in:
parent
8cb3c07151
commit
b8d3d8f5e4
|
@ -1479,12 +1479,14 @@ WinMain(HINSTANCE instance,
|
|||
RwChar** argv;
|
||||
SystemParametersInfo(SPI_SETFOREGROUNDLOCKTIMEOUT, 0, nil, SPIF_SENDCHANGE);
|
||||
|
||||
#if 1
|
||||
// TODO: make this an option somewhere
|
||||
AllocConsole();
|
||||
freopen("CONIN$", "r", stdin);
|
||||
freopen("CONOUT$", "w", stdout);
|
||||
freopen("CONOUT$", "w", stderr);
|
||||
#ifndef MASTER
|
||||
if (strstr(cmdLine, "-console"))
|
||||
{
|
||||
AllocConsole();
|
||||
freopen("CONIN$", "r", stdin);
|
||||
freopen("CONOUT$", "w", stdout);
|
||||
freopen("CONOUT$", "w", stderr);
|
||||
}
|
||||
#endif
|
||||
|
||||
#else
|
||||
|
|
|
@ -2005,11 +2005,15 @@ WinMain(HINSTANCE instance,
|
|||
RwChar **argv;
|
||||
SystemParametersInfo(SPI_SETFOREGROUNDLOCKTIMEOUT, 0, nil, SPIF_SENDCHANGE);
|
||||
|
||||
// TODO: make this an option somewhere
|
||||
AllocConsole();
|
||||
freopen("CONIN$", "r", stdin);
|
||||
freopen("CONOUT$", "w", stdout);
|
||||
freopen("CONOUT$", "w", stderr);
|
||||
#ifndef MASTER
|
||||
if (strstr(cmdLine, "-console"))
|
||||
{
|
||||
AllocConsole();
|
||||
freopen("CONIN$", "r", stdin);
|
||||
freopen("CONOUT$", "w", stdout);
|
||||
freopen("CONOUT$", "w", stderr);
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Initialize the platform independent data.
|
||||
|
|
Loading…
Reference in a new issue