summaryrefslogtreecommitdiffstats
path: root/src/core/hid/emulated_console.cpp
diff options
context:
space:
mode:
authorgerman77 <juangerman-13@hotmail.com>2021-10-31 04:23:10 +0100
committerNarr the Reg <juangerman-13@hotmail.com>2021-11-25 03:30:26 +0100
commit2b1b0c2a30e242b08ec120e09803ec54d5445703 (patch)
tree9a10400a7e4403b288eee3aae8a52f1d5be912de /src/core/hid/emulated_console.cpp
parentinput_common: Revert deleted TAS functions (diff)
downloadyuzu-2b1b0c2a30e242b08ec120e09803ec54d5445703.tar
yuzu-2b1b0c2a30e242b08ec120e09803ec54d5445703.tar.gz
yuzu-2b1b0c2a30e242b08ec120e09803ec54d5445703.tar.bz2
yuzu-2b1b0c2a30e242b08ec120e09803ec54d5445703.tar.lz
yuzu-2b1b0c2a30e242b08ec120e09803ec54d5445703.tar.xz
yuzu-2b1b0c2a30e242b08ec120e09803ec54d5445703.tar.zst
yuzu-2b1b0c2a30e242b08ec120e09803ec54d5445703.zip
Diffstat (limited to 'src/core/hid/emulated_console.cpp')
-rw-r--r--src/core/hid/emulated_console.cpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/core/hid/emulated_console.cpp b/src/core/hid/emulated_console.cpp
index d1d4a5355..c259de0f1 100644
--- a/src/core/hid/emulated_console.cpp
+++ b/src/core/hid/emulated_console.cpp
@@ -55,21 +55,21 @@ void EmulatedConsole::SetTouchParams() {
void EmulatedConsole::ReloadInput() {
SetTouchParams();
- motion_devices = Input::CreateDevice<Input::InputDevice>(motion_params);
+ motion_devices = Common::Input::CreateDevice<Common::Input::InputDevice>(motion_params);
if (motion_devices) {
- Input::InputCallback motion_callback{
- [this](Input::CallbackStatus callback) { SetMotion(callback); }};
+ Common::Input::InputCallback motion_callback{
+ [this](Common::Input::CallbackStatus callback) { SetMotion(callback); }};
motion_devices->SetCallback(motion_callback);
}
std::size_t index = 0;
for (auto& touch_device : touch_devices) {
- touch_device = Input::CreateDevice<Input::InputDevice>(touch_params[index]);
+ touch_device = Common::Input::CreateDevice<Common::Input::InputDevice>(touch_params[index]);
if (!touch_device) {
continue;
}
- Input::InputCallback touch_callback{
- [this, index](Input::CallbackStatus callback) { SetTouch(callback, index); }};
+ Common::Input::InputCallback touch_callback{
+ [this, index](Common::Input::CallbackStatus callback) { SetTouch(callback, index); }};
touch_device->SetCallback(touch_callback);
index++;
}
@@ -117,7 +117,7 @@ void EmulatedConsole::SetMotionParam(Common::ParamPackage param) {
ReloadInput();
}
-void EmulatedConsole::SetMotion(Input::CallbackStatus callback) {
+void EmulatedConsole::SetMotion(Common::Input::CallbackStatus callback) {
std::lock_guard lock{mutex};
auto& raw_status = console.motion_values.raw_status;
auto& emulated = console.motion_values.emulated;
@@ -152,7 +152,8 @@ void EmulatedConsole::SetMotion(Input::CallbackStatus callback) {
TriggerOnChange(ConsoleTriggerType::Motion);
}
-void EmulatedConsole::SetTouch(Input::CallbackStatus callback, [[maybe_unused]] std::size_t index) {
+void EmulatedConsole::SetTouch(Common::Input::CallbackStatus callback,
+ [[maybe_unused]] std::size_t index) {
if (index >= console.touch_values.size()) {
return;
}