diff options
author | german77 <juangerman-13@hotmail.com> | 2022-09-25 02:46:49 +0200 |
---|---|---|
committer | german77 <juangerman-13@hotmail.com> | 2022-10-02 19:32:26 +0200 |
commit | e8d71712e7054748e7e18de9362de1f5a394b46b (patch) | |
tree | 263779f72b874d81513f1292bb413a2cf170f32d /src/common/input.h | |
parent | Merge pull request #8934 from german77/palma_release (diff) | |
download | yuzu-e8d71712e7054748e7e18de9362de1f5a394b46b.tar yuzu-e8d71712e7054748e7e18de9362de1f5a394b46b.tar.gz yuzu-e8d71712e7054748e7e18de9362de1f5a394b46b.tar.bz2 yuzu-e8d71712e7054748e7e18de9362de1f5a394b46b.tar.lz yuzu-e8d71712e7054748e7e18de9362de1f5a394b46b.tar.xz yuzu-e8d71712e7054748e7e18de9362de1f5a394b46b.tar.zst yuzu-e8d71712e7054748e7e18de9362de1f5a394b46b.zip |
Diffstat (limited to '')
-rw-r--r-- | src/common/input.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/src/common/input.h b/src/common/input.h index 825b0d650..8365cc36e 100644 --- a/src/common/input.h +++ b/src/common/input.h @@ -76,6 +76,19 @@ enum class PollingError { Unknown, }; +// Nfc reply from the controller +enum class NfcState { + Success, + NewAmiibo, + WaitingForAmiibo, + AmiiboRemoved, + NotAnAmiibo, + NotSupported, + WrongDeviceState, + WriteFailed, + Unknown, +}; + // Ir camera reply from the controller enum class CameraError { None, @@ -202,6 +215,11 @@ struct CameraStatus { std::vector<u8> data{}; }; +struct NfcStatus { + NfcState state{}; + std::vector<u8> data{}; +}; + // List of buttons to be passed to Qt that can be translated enum class ButtonNames { Undefined, @@ -260,6 +278,7 @@ struct CallbackStatus { BatteryStatus battery_status{}; VibrationStatus vibration_status{}; CameraStatus camera_status{}; + NfcStatus nfc_status{}; }; // Triggered once every input change @@ -312,6 +331,14 @@ public: virtual CameraError SetCameraFormat([[maybe_unused]] CameraFormat camera_format) { return CameraError::NotSupported; } + + virtual NfcState SupportsNfc() { + return NfcState::NotSupported; + } + + virtual NfcState WriteNfcData([[maybe_unused]] const std::vector<u8>& data) { + return NfcState::NotSupported; + } }; /// An abstract class template for a factory that can create input devices. |