summaryrefslogtreecommitdiff
path: root/src/input/joystick.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-05-18 17:26:57 +0300
committerAndrei Karas <akaras@inbox.ru>2014-05-18 17:26:57 +0300
commitefeb84b086052aeefd9d190a4a0676b8a81b651c (patch)
tree9643135eddf409c7dc8b0545046bc76a44521ec2 /src/input/joystick.cpp
parent8b94ceca60560fd06f60359492c47684eda57e5c (diff)
downloadmv-efeb84b086052aeefd9d190a4a0676b8a81b651c.tar.gz
mv-efeb84b086052aeefd9d190a4a0676b8a81b651c.tar.bz2
mv-efeb84b086052aeefd9d190a4a0676b8a81b651c.tar.xz
mv-efeb84b086052aeefd9d190a4a0676b8a81b651c.zip
Move inputtype into separate file.
Diffstat (limited to 'src/input/joystick.cpp')
-rw-r--r--src/input/joystick.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/input/joystick.cpp b/src/input/joystick.cpp
index 7343ec00c..2368876cc 100644
--- a/src/input/joystick.cpp
+++ b/src/input/joystick.cpp
@@ -28,6 +28,7 @@
#include "sdlshared.h"
#include "input/inputmanager.h"
+#include "input/inputtype.h"
#include "utils/timer.h"
@@ -278,7 +279,7 @@ void Joystick::getNames(std::vector <std::string> &names)
void Joystick::update()
{
inputManager.updateKeyActionMap(mKeyToAction, mKeyToId,
- mKeyTimeMap, INPUT_JOYSTICK);
+ mKeyTimeMap, InputType::JOYSTICK);
}
KeysVector *Joystick::getActionVector(const SDL_Event &event)
@@ -319,7 +320,7 @@ bool Joystick::isActionActive(const int index) const
for (size_t i = 0; i < KeyFunctionSize; i ++)
{
const KeyItem &val = key.values[i];
- if (val.type != INPUT_JOYSTICK)
+ if (val.type != InputType::JOYSTICK)
continue;
const int value = val.value;
if (value >= 0 && value < mButtonsNumber)