aboutsummaryrefslogtreecommitdiff
path: root/src/input_common
diff options
context:
space:
mode:
authorlizzie <lizzie@eden-emu.dev>2026-06-04 05:49:07 +0200
committercrueter <crueter@eden-emu.dev>2026-06-04 05:49:07 +0200
commit89199f4d279bff0c664fb9142b1945d0c6d93ee8 (patch)
treef7223e46b4d1ecf0355adc5fc9363bae093dcf89 /src/input_common
parent978d9d935d50fd09af5c6173582b1d63792900bd (diff)
[*] basic in-house cpp linting (#4039)
- add `#pragma once` to remainder files - "correcter" defines (ANDROID), see https://groups.google.com/g/android-ndk/c/cf9_f1SLXls - extra miscelly fixups Signed-off-by: lizzie <lizzie@eden-emu.dev> Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/4039 Reviewed-by: MaranBr <maranbr@eden-emu.dev> Reviewed-by: crueter <crueter@eden-emu.dev>
Diffstat (limited to 'src/input_common')
-rw-r--r--src/input_common/main.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/input_common/main.cpp b/src/input_common/main.cpp
index 5f0a8af3aa..6c8443ff62 100644
--- a/src/input_common/main.cpp
+++ b/src/input_common/main.cpp
@@ -30,7 +30,7 @@
#include "input_common/drivers/sdl_driver.h"
#endif
-#ifdef ANDROID
+#ifdef __ANDROID__
#include "input_common/drivers/android.h"
#endif
@@ -85,7 +85,7 @@ struct InputSubsystem::Impl {
RegisterEngine("cemuhookudp", udp_client);
RegisterEngine("tas", tas_input);
RegisterEngine("camera", camera);
-#ifdef ANDROID
+#ifdef __ANDROID__
RegisterEngine("android", android);
#endif
RegisterEngine("virtual_amiibo", virtual_amiibo);
@@ -119,7 +119,7 @@ struct InputSubsystem::Impl {
UnregisterEngine(udp_client);
UnregisterEngine(tas_input);
UnregisterEngine(camera);
-#ifdef ANDROID
+#ifdef __ANDROID__
UnregisterEngine(android);
#endif
UnregisterEngine(virtual_amiibo);
@@ -138,13 +138,13 @@ struct InputSubsystem::Impl {
Common::ParamPackage{{"display", "Any"}, {"engine", "any"}},
};
-#ifndef ANDROID
+#ifndef __ANDROID__
auto keyboard_devices = keyboard->GetInputDevices();
devices.insert(devices.end(), keyboard_devices.begin(), keyboard_devices.end());
auto mouse_devices = mouse->GetInputDevices();
devices.insert(devices.end(), mouse_devices.begin(), mouse_devices.end());
#endif
-#ifdef ANDROID
+#ifdef __ANDROID__
auto android_devices = android->GetInputDevices();
devices.insert(devices.end(), android_devices.begin(), android_devices.end());
#endif
@@ -176,7 +176,7 @@ struct InputSubsystem::Impl {
if (engine == mouse->GetEngineName()) {
return mouse;
}
-#ifdef ANDROID
+#ifdef __ANDROID__
if (engine == android->GetEngineName()) {
return android;
}
@@ -261,7 +261,7 @@ struct InputSubsystem::Impl {
if (engine == mouse->GetEngineName()) {
return true;
}
-#ifdef ANDROID
+#ifdef __ANDROID__
if (engine == android->GetEngineName()) {
return true;
}
@@ -294,7 +294,7 @@ struct InputSubsystem::Impl {
void BeginConfiguration() {
keyboard->BeginConfiguration();
mouse->BeginConfiguration();
-#ifdef ANDROID
+#ifdef __ANDROID__
android->BeginConfiguration();
#endif
#ifdef ENABLE_LIBUSB
@@ -310,7 +310,7 @@ struct InputSubsystem::Impl {
void EndConfiguration() {
keyboard->EndConfiguration();
mouse->EndConfiguration();
-#ifdef ANDROID
+#ifdef __ANDROID__
android->EndConfiguration();
#endif
#ifdef ENABLE_LIBUSB
@@ -355,7 +355,7 @@ struct InputSubsystem::Impl {
std::shared_ptr<Joycons> joycon;
#endif
-#ifdef ANDROID
+#ifdef __ANDROID__
std::shared_ptr<Android> android;
#endif
};
@@ -412,7 +412,7 @@ const Camera* InputSubsystem::GetCamera() const {
return impl->camera.get();
}
-#ifdef ANDROID
+#ifdef __ANDROID__
Android* InputSubsystem::GetAndroid() {
return impl->android.get();
}