Skip to content

Commit

Permalink
Merge pull request #168 from h0tw1r3/master
Browse files Browse the repository at this point in the history
Hide console instead of closing it, fixes #164
  • Loading branch information
mickelson committed Dec 22, 2015
2 parents 4f17b9d + 8e775a8 commit 5e74264
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/fe_util.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -723,12 +723,6 @@ bool run_program( const std::string &prog,
si.dwFlags |= STARTF_USESTDHANDLES;
}

if ( !have_console() )
{
si.dwFlags |= STARTF_USESHOWWINDOW;
si.wShowWindow = SW_HIDE;
}

LPSTR cmdline = new char[ comstr.length() + 1 ];
strncpy( cmdline, comstr.c_str(), comstr.length() + 1 );

Expand Down Expand Up @@ -1029,7 +1023,8 @@ void preinit_helper()
#ifdef SFML_SYSTEM_WINDOWS
if ( !have_console() )
{
FreeConsole();
HWND handle = GetConsoleWindow();
ShowWindow(handle, SW_HIDE);
}
#endif
}
Expand Down

0 comments on commit 5e74264

Please sign in to comment.