From ed036df3ce0253fe639a441c22a58ecc0f9a116a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?eray=20or=C3=A7unus?= Date: Fri, 3 Jul 2020 05:40:22 +0300 Subject: Re-enable console for debugging frontend --- src/skel/glfw/glfw.cpp | 6 ++++++ src/skel/win/win.cpp | 3 +-- 2 files changed, 7 insertions(+), 2 deletions(-) (limited to 'src/skel') diff --git a/src/skel/glfw/glfw.cpp b/src/skel/glfw/glfw.cpp index 0728f6c2..5e0c178c 100644 --- a/src/skel/glfw/glfw.cpp +++ b/src/skel/glfw/glfw.cpp @@ -1366,6 +1366,12 @@ WinMain(HINSTANCE instance, RwInt32 argc; 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); #else int main(int argc, char *argv[]) diff --git a/src/skel/win/win.cpp b/src/skel/win/win.cpp index 484c6fe8..e1fb5b7f 100644 --- a/src/skel/win/win.cpp +++ b/src/skel/win/win.cpp @@ -1929,13 +1929,12 @@ WinMain(HINSTANCE instance, StaticPatcher::Apply(); 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); -*/ /* * Initialize the platform independent data. -- cgit v1.2.3 From 1cea84d2b1673bfd86e1698c27c381e1488c77cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?eray=20or=C3=A7unus?= Date: Sat, 4 Jul 2020 16:00:41 +0300 Subject: Remove console and fix sth --- src/skel/glfw/glfw.cpp | 3 +++ src/skel/win/win.cpp | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) (limited to 'src/skel') diff --git a/src/skel/glfw/glfw.cpp b/src/skel/glfw/glfw.cpp index 5e0c178c..21aace7a 100644 --- a/src/skel/glfw/glfw.cpp +++ b/src/skel/glfw/glfw.cpp @@ -1367,11 +1367,14 @@ WinMain(HINSTANCE instance, RwChar** argv; SystemParametersInfo(SPI_SETFOREGROUNDLOCKTIMEOUT, 0, nil, SPIF_SENDCHANGE); +#if 0 // TODO: make this an option somewhere AllocConsole(); freopen("CONIN$", "r", stdin); freopen("CONOUT$", "w", stdout); freopen("CONOUT$", "w", stderr); +#endif + #else int main(int argc, char *argv[]) diff --git a/src/skel/win/win.cpp b/src/skel/win/win.cpp index e1fb5b7f..52941d7d 100644 --- a/src/skel/win/win.cpp +++ b/src/skel/win/win.cpp @@ -1929,12 +1929,13 @@ WinMain(HINSTANCE instance, StaticPatcher::Apply(); SystemParametersInfo(SPI_SETFOREGROUNDLOCKTIMEOUT, 0, nil, SPIF_SENDCHANGE); - +#if 0 // TODO: make this an option somewhere AllocConsole(); freopen("CONIN$", "r", stdin); freopen("CONOUT$", "w", stdout); freopen("CONOUT$", "w", stderr); +#endif /* * Initialize the platform independent data. -- cgit v1.2.3