diff --git a/radiant/main.cpp b/radiant/main.cpp index ede1426..19297d7 100644 --- a/radiant/main.cpp +++ b/radiant/main.cpp @@ -51,6 +51,26 @@ bool g_bBuildList = false; int g_argc; char** g_argv; +// ============================================================================= +// Windows WinMain() wrapper for main() +// used in Release Builds to suppress the Console +#if defined(_WIN32) + +#include + +int main(int argc, char* argv[]); + +int CALLBACK WinMain( + __in HINSTANCE hInstance, + __in HINSTANCE hPrevInstance, + __in LPSTR lpCmdLine, + __in int nCmdShow +){ + return main(__argc, __argv); +} + +#endif + // ============================================================================= // Splash screen diff --git a/radiant/radiant.vcproj b/radiant/radiant.vcproj index 851666b..81af2a2 100644 --- a/radiant/radiant.vcproj +++ b/radiant/radiant.vcproj @@ -135,7 +135,7 @@ AdditionalDependencies="Ws2_32.lib glib-2.0.lib gobject-2.0.lib intl.lib gtk-win32-2.0.lib gdk-win32-2.0.lib pango-1.0.lib pangoft2-1.0.lib gdkglext-win32-1.0.lib gtkglext-win32-1.0.lib libxml2.lib mathlib.lib synapse.lib l_net.lib cmdlib.lib" AdditionalLibraryDirectories=""$(SolutionDir)\..\gtk-2.16.6\lib";"$(SolutionDir)\..\libxml2-2.7.3\lib";"$(SolutionDir)\..\gtkglext-1.2.0\lib";"$(SolutionDir)\build\$(ConfigurationName)\libs"" GenerateDebugInformation="true" - SubSystem="1" + SubSystem="2" OptimizeReferences="2" EnableCOMDATFolding="2" TargetMachine="1"