summaryrefslogtreecommitdiff
path: root/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
diff options
context:
space:
mode:
authorNeoBrainX <NeoBrainX@googlemail.com>2013-03-01 01:07:34 +0100
committerNeoBrainX <NeoBrainX@googlemail.com>2013-03-01 01:07:34 +0100
commit7682ed22c6d584bd276c1049c9b5068b1610da61 (patch)
treeea65d89f5b4b172bc1bbbd437ebc28752f336332 /Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
parent0f617183a8a74f066d1d01a3ed50042cc9824bf8 (diff)
parentbc15919e2ebefe327ce6330f7abdaccaa2fd2004 (diff)
Merge branch 'master' into perfqueries.
Conflicts: Source/Core/VideoCommon/Src/VideoConfig.h Source/Core/VideoCommon/VideoCommon.vcxproj.filters Source/Plugins/Plugin_VideoDX11/Src/VertexManager.cpp Source/Plugins/Plugin_VideoSoftware/Src/Rasterizer.cpp Source/Plugins/Plugin_VideoSoftware/Src/Tev.cpp
Diffstat (limited to 'Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp')
-rw-r--r--Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp b/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
index 82cfe2469e..8e96231674 100644
--- a/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
+++ b/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
@@ -45,7 +45,7 @@ void ControllerInterface::Initialize()
ciface::Xlib::Init(m_devices, m_hwnd);
#endif
#ifdef CIFACE_USE_OSX
- ciface::OSX::Init(m_devices);
+ ciface::OSX::Init(m_devices, m_hwnd);
#endif
#ifdef CIFACE_USE_SDL
ciface::SDL::Init(m_devices);
@@ -461,7 +461,7 @@ ControllerInterface::Device::Control* ControllerInterface::InputReference::Detec
i = device->Inputs().begin(),
e = device->Inputs().end();
for (std::vector<bool>::iterator state = states.begin(); i != e; ++i)
- *state++ = ((*i)->GetState() > INPUT_DETECT_THRESHOLD);
+ *state++ = ((*i)->GetState() > (1 - INPUT_DETECT_THRESHOLD));
while (time < ms)
{
@@ -477,7 +477,7 @@ ControllerInterface::Device::Control* ControllerInterface::InputReference::Detec
if (false == *state)
return *i;
}
- else
+ else if ((*i)->GetState() < (1 - INPUT_DETECT_THRESHOLD))
*state = false;
}
Common::SleepCurrentThread(10); time += 10;