mirror of
https://github.com/WerWolv/ImHex.git
synced 2026-03-30 05:05:19 -05:00
Properly added back console window on Windows debug builds
This commit is contained in:
@@ -18,10 +18,6 @@
|
||||
#include <glad/glad.h>
|
||||
#include <GLFW/glfw3.h>
|
||||
|
||||
#if defined(OS_WINDOWS)
|
||||
#include <windows.h>
|
||||
#endif
|
||||
|
||||
namespace hex {
|
||||
|
||||
constexpr auto MenuBarItems = { "File", "Edit", "View", "Help" };
|
||||
@@ -53,19 +49,6 @@ namespace hex {
|
||||
hex::SharedData::mainArgc = argc;
|
||||
hex::SharedData::mainArgv = argv;
|
||||
|
||||
// Try to attach to a currently open console on Windows if available
|
||||
#if defined(OS_WINDOWS)
|
||||
if (AttachConsole(ATTACH_PARENT_PROCESS)) {
|
||||
HANDLE hStdOut = GetStdHandle(STD_OUTPUT_HANDLE);
|
||||
if (hStdOut != INVALID_HANDLE_VALUE) {
|
||||
freopen("CONOUT$", "w", stdout);
|
||||
freopen("CONERR$", "w", stderr);
|
||||
setvbuf(stdout, nullptr, _IONBF, 0);
|
||||
setvbuf(stderr, nullptr, _IONBF, 0);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
this->initGLFW();
|
||||
this->initImGui();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user