diff options
Diffstat (limited to 'src/core/hid/input_converter.cpp')
| -rw-r--r-- | src/core/hid/input_converter.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/core/hid/input_converter.cpp b/src/core/hid/input_converter.cpp index 52fb69e9c..fe9915abe 100644 --- a/src/core/hid/input_converter.cpp +++ b/src/core/hid/input_converter.cpp | |||
| @@ -287,6 +287,20 @@ Common::Input::CameraStatus TransformToCamera(const Common::Input::CallbackStatu | |||
| 287 | return camera; | 287 | return camera; |
| 288 | } | 288 | } |
| 289 | 289 | ||
| 290 | Common::Input::NfcStatus TransformToNfc(const Common::Input::CallbackStatus& callback) { | ||
| 291 | Common::Input::NfcStatus nfc{}; | ||
| 292 | switch (callback.type) { | ||
| 293 | case Common::Input::InputType::Nfc: | ||
| 294 | return callback.nfc_status; | ||
| 295 | break; | ||
| 296 | default: | ||
| 297 | LOG_ERROR(Input, "Conversion from type {} to NFC not implemented", callback.type); | ||
| 298 | break; | ||
| 299 | } | ||
| 300 | |||
| 301 | return nfc; | ||
| 302 | } | ||
| 303 | |||
| 290 | void SanitizeAnalog(Common::Input::AnalogStatus& analog, bool clamp_value) { | 304 | void SanitizeAnalog(Common::Input::AnalogStatus& analog, bool clamp_value) { |
| 291 | const auto& properties = analog.properties; | 305 | const auto& properties = analog.properties; |
| 292 | float& raw_value = analog.raw_value; | 306 | float& raw_value = analog.raw_value; |