Refactored the code a bit

Remember when I spoke of "a cleaner app.d"? Well, it's reality now,
thanks to `mixin template main` and `mixin template WinMain`
WinMain wasn't properly behind version statements

Would've probably caused slight issues on non-Windows platforms, such as
nothing compiling.