summaryrefslogtreecommitdiff
path: root/Source
diff options
context:
space:
mode:
authorRyan Houdek <Sonicadvance1@gmail.com>2016-01-19 02:15:25 -0500
committerRyan Houdek <Sonicadvance1@gmail.com>2016-01-19 02:15:25 -0500
commit7b9eeba168a4b2774898e60dc86f1ca108090bf7 (patch)
tree316eb9a6850d7df026399bb3559ee686c9e0223c /Source
parent51a36f27e0c91ac819d077c6a9242cac5a8085ed (diff)
parent6862d7c7b2451614fc40d9e5072b09595c331be9 (diff)
Merge pull request #3479 from Sonicadvance1/fix_hotkeys
Fix hotkeys not reporting inputs.
Diffstat (limited to 'Source')
-rw-r--r--Source/Core/Core/HW/GCPad.cpp9
-rw-r--r--Source/Core/Core/HW/SI.cpp5
2 files changed, 5 insertions, 9 deletions
diff --git a/Source/Core/Core/HW/GCPad.cpp b/Source/Core/Core/HW/GCPad.cpp
index ce3cda6b53..356ca5f996 100644
--- a/Source/Core/Core/HW/GCPad.cpp
+++ b/Source/Core/Core/HW/GCPad.cpp
@@ -10,7 +10,6 @@
#include "Core/HW/GCPadEmu.h"
#include "InputCommon/GCPadStatus.h"
#include "InputCommon/InputConfig.h"
-#include "InputCommon/ControllerInterface/ControllerInterface.h"
namespace Pad
{
@@ -53,14 +52,6 @@ void GetStatus(u8 pad_num, GCPadStatus* pad_status)
memset(pad_status, 0, sizeof(*pad_status));
pad_status->err = PAD_ERR_NONE;
- // If we are on the next input cycle, update output and input
- static int last_pad_num = 4;
- if (pad_num <= last_pad_num)
- {
- g_controller_interface.UpdateInput();
- }
- last_pad_num = pad_num;
-
// Get input
static_cast<GCPad*>(s_config.GetController(pad_num))->GetInput(pad_status);
}
diff --git a/Source/Core/Core/HW/SI.cpp b/Source/Core/Core/HW/SI.cpp
index 5476d6c563..87db67b9e3 100644
--- a/Source/Core/Core/HW/SI.cpp
+++ b/Source/Core/Core/HW/SI.cpp
@@ -18,6 +18,7 @@
#include "Core/HW/SI.h"
#include "Core/HW/SI_DeviceGBA.h"
+#include "InputCommon/ControllerInterface/ControllerInterface.h"
namespace SerialInterface
{
@@ -511,6 +512,10 @@ void ChangeDevice(SIDevices device, int channel)
void UpdateDevices()
{
+ // Update inputs at the rate of SI
+ // Typically 120hz but is variable
+ g_controller_interface.UpdateInput();
+
// Update channels and set the status bit if there's new data
g_StatusReg.RDST0 = !!g_Channel[0].m_device->GetData(g_Channel[0].m_InHi.Hex, g_Channel[0].m_InLo.Hex);
g_StatusReg.RDST1 = !!g_Channel[1].m_device->GetData(g_Channel[1].m_InHi.Hex, g_Channel[1].m_InLo.Hex);