summaryrefslogtreecommitdiff
path: root/src/maingui.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-09-23 22:01:44 +0300
committerAndrei Karas <akaras@inbox.ru>2016-09-23 22:01:44 +0300
commit3c404128c4669a1f4f190e20a89553677717fc50 (patch)
tree2db4e5031089c800c4e00fd6244e578f44a7c910 /src/maingui.cpp
parent89b267d6d73bbc59f7c313b8a22b97fbb27f99a8 (diff)
downloadplus-3c404128c4669a1f4f190e20a89553677717fc50.tar.gz
plus-3c404128c4669a1f4f190e20a89553677717fc50.tar.bz2
plus-3c404128c4669a1f4f190e20a89553677717fc50.tar.xz
plus-3c404128c4669a1f4f190e20a89553677717fc50.zip
Add missing comments into defines.
Diffstat (limited to 'src/maingui.cpp')
-rw-r--r--src/maingui.cpp33
1 files changed, 18 insertions, 15 deletions
diff --git a/src/maingui.cpp b/src/maingui.cpp
index 528ccf3a9..f3602feb7 100644
--- a/src/maingui.cpp
+++ b/src/maingui.cpp
@@ -30,7 +30,7 @@
#ifdef ANDROID
#include "utils/mkdir.h"
#include "utils/paths.h"
-#endif
+#endif // ANDROID
#include "utils/physfscheckutils.h"
#include "utils/physfsrwops.h"
#include "utils/process.h"
@@ -38,7 +38,7 @@
#ifdef __MINGW32__
#include <windows.h>
-#endif
+#endif // __MINGW32__
#include <iostream>
@@ -47,7 +47,7 @@
#ifndef SDL_VERSIONNUM
#error missing <SDL_version.h>
-#endif
+#endif // SDL_VERSIONNUM
#define SDL_IMAGE_COMPILEDVERSION \
SDL_VERSIONNUM(SDL_IMAGE_MAJOR_VERSION, \
@@ -70,15 +70,16 @@ char *selfName = nullptr;
#ifndef UNITTESTS
#ifdef ANDROID
int main(int argc, char *argv[])
-#else
+#else // ANDROID
+
int mainGui(int argc, char *argv[])
-#endif
+#endif // ANDROID
{
#if defined(__MINGW32__)
// load mingw crash handler. Won't fail if dll is not present.
// may load libray from current dir, it may not same as program dir
LoadLibrary("exchndl.dll");
-#endif
+#endif // defined(__MINGW32__)
selfName = argv[0];
@@ -88,20 +89,21 @@ int mainGui(int argc, char *argv[])
#ifdef ANDROID
mkdir_r(getSdStoragePath().c_str());
-#endif
+#endif // ANDROID
PhysFs::init(argv[0]);
XML::initXML();
#if SDL_IMAGE_VERSION_ATLEAST(1, 2, 11)
IMG_Init(IMG_INIT_PNG);
-#endif
+#endif // SDL_IMAGE_VERSION_ATLEAST(1, 2, 11)
#if SDL_MIXER_VERSION_ATLEAST(1, 2, 11)
Mix_Init(MIX_INIT_OGG);
-#endif
+#endif // SDL_MIXER_VERSION_ATLEAST(1, 2, 11)
#ifdef WIN32
SetCurrentDirectory(PhysFs::getBaseDir());
-#endif
+#endif // WIN32
+
setPriority(true);
client = new Client;
int ret = 0;
@@ -119,17 +121,18 @@ int mainGui(int argc, char *argv[])
#if SDL_MIXER_VERSION_ATLEAST(1, 2, 11)
Mix_Quit();
-#endif
+#endif // SDL_MIXER_VERSION_ATLEAST(1, 2, 11)
#if SDL_IMAGE_VERSION_ATLEAST(1, 2, 11)
IMG_Quit();
-#endif
+#endif // SDL_IMAGE_VERSION_ATLEAST(1, 2, 11)
#ifdef DUMP_LEAKED_RESOURCES
reportRWops();
-#endif
+#endif // DUMP_LEAKED_RESOURCES
#ifdef DEBUG_PHYSFS
reportPhysfsLeaks();
-#endif
+#endif // DEBUG_PHYSFS
+
return ret;
}
-#endif
+#endif // UNITTESTS