summaryrefslogtreecommitdiff
path: root/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
diff options
context:
space:
mode:
authorRyan Houdek <Sonicadvance1@gmail.com>2013-04-14 23:02:53 -0500
committerRyan Houdek <Sonicadvance1@gmail.com>2013-04-14 23:02:53 -0500
commit44bbb54a62a58be4ad39caf6ba55ff98244223d5 (patch)
treec5654ff4ac41a7bf36133a868f61628757663f37 /Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
parent37b67971e7def8dcd0dae3209afc6c69b52d0609 (diff)
Add a Androind ControllerInterface class for allowing input in a non-hacky way. Add a default GCPad.ini file so it actually works.
Diffstat (limited to 'Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp')
-rw-r--r--Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp b/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
index 8e96231674..dccd622519 100644
--- a/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
+++ b/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
@@ -15,6 +15,9 @@
#ifdef CIFACE_USE_SDL
#include "SDL/SDL.h"
#endif
+#ifdef CIFACE_USE_ANDROID
+ #include "Android/Android.h"
+#endif
#include "Thread.h"
@@ -50,6 +53,9 @@ void ControllerInterface::Initialize()
#ifdef CIFACE_USE_SDL
ciface::SDL::Init(m_devices);
#endif
+#ifdef CIFACE_USE_ANDROID
+ ciface::Android::Init(m_devices);
+#endif
m_is_init = true;
}
@@ -100,6 +106,9 @@ void ControllerInterface::Shutdown()
// TODO: there seems to be some sort of memory leak with SDL, quit isn't freeing everything up
SDL_Quit();
#endif
+#ifdef CIFACE_USE_ANDROID
+ // nothing needed
+#endif
m_is_init = false;
}