mirror of
https://github.com/elasota/Aerofoil.git
synced 2025-09-23 06:53:43 +00:00
AerofoilX logging fixes
This commit is contained in:
@@ -29,14 +29,26 @@ IGpInputDriver *GpDriver_CreateInputDriver_SDL2_Gamepad(const GpInputDriverPrope
|
||||
|
||||
SDLMAIN_DECLSPEC int SDL_main(int argc, char *argv[])
|
||||
{
|
||||
GpLogDriver_X::Init();
|
||||
bool enableLogging = false;
|
||||
for (int i = 1; i < argc; i++)
|
||||
{
|
||||
if (!strcmp(argv[i], "-diagnostics"))
|
||||
enableLogging = true;
|
||||
}
|
||||
|
||||
if (SDL_Init(SDL_INIT_VIDEO | SDL_INIT_GAMECONTROLLER) < 0)
|
||||
return -1;
|
||||
|
||||
GpFileSystem_X::GetInstance()->Init();
|
||||
|
||||
IGpLogDriver *logger = GpLogDriver_X::GetInstance();
|
||||
IGpLogDriver *logger = nullptr;
|
||||
|
||||
if (enableLogging)
|
||||
{
|
||||
GpLogDriver_X::Init();
|
||||
logger = GpLogDriver_X::GetInstance();
|
||||
}
|
||||
|
||||
GpDriverCollection *drivers = GpAppInterface_Get()->PL_GetDriverCollection();
|
||||
|
||||
drivers->SetDriver<GpDriverIDs::kFileSystem>(GpFileSystem_X::GetInstance());
|
||||
|
Reference in New Issue
Block a user