diff options
| author | 2022-12-26 11:11:01 -0600 | |
|---|---|---|
| committer | 2023-01-19 18:05:22 -0600 | |
| commit | 527dad70976a158e94defc51707347e064a31099 (patch) | |
| tree | d9e9e68799d0c051e8e6a8a2dda7170ea911831d /src/input_common/drivers/gc_adapter.cpp | |
| parent | Address review comments (diff) | |
| download | yuzu-527dad70976a158e94defc51707347e064a31099.tar.gz yuzu-527dad70976a158e94defc51707347e064a31099.tar.xz yuzu-527dad70976a158e94defc51707347e064a31099.zip | |
input_common: Use DriverResult on all engines
Diffstat (limited to 'src/input_common/drivers/gc_adapter.cpp')
| -rw-r--r-- | src/input_common/drivers/gc_adapter.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/input_common/drivers/gc_adapter.cpp b/src/input_common/drivers/gc_adapter.cpp index 826fa2109..ecb3e9dc2 100644 --- a/src/input_common/drivers/gc_adapter.cpp +++ b/src/input_common/drivers/gc_adapter.cpp | |||
| @@ -324,7 +324,7 @@ bool GCAdapter::GetGCEndpoint(libusb_device* device) { | |||
| 324 | return true; | 324 | return true; |
| 325 | } | 325 | } |
| 326 | 326 | ||
| 327 | Common::Input::VibrationError GCAdapter::SetVibration( | 327 | Common::Input::DriverResult GCAdapter::SetVibration( |
| 328 | const PadIdentifier& identifier, const Common::Input::VibrationStatus& vibration) { | 328 | const PadIdentifier& identifier, const Common::Input::VibrationStatus& vibration) { |
| 329 | const auto mean_amplitude = (vibration.low_amplitude + vibration.high_amplitude) * 0.5f; | 329 | const auto mean_amplitude = (vibration.low_amplitude + vibration.high_amplitude) * 0.5f; |
| 330 | const auto processed_amplitude = | 330 | const auto processed_amplitude = |
| @@ -333,9 +333,9 @@ Common::Input::VibrationError GCAdapter::SetVibration( | |||
| 333 | pads[identifier.port].rumble_amplitude = processed_amplitude; | 333 | pads[identifier.port].rumble_amplitude = processed_amplitude; |
| 334 | 334 | ||
| 335 | if (!rumble_enabled) { | 335 | if (!rumble_enabled) { |
| 336 | return Common::Input::VibrationError::Disabled; | 336 | return Common::Input::DriverResult::Disabled; |
| 337 | } | 337 | } |
| 338 | return Common::Input::VibrationError::None; | 338 | return Common::Input::DriverResult::Success; |
| 339 | } | 339 | } |
| 340 | 340 | ||
| 341 | bool GCAdapter::IsVibrationEnabled([[maybe_unused]] const PadIdentifier& identifier) { | 341 | bool GCAdapter::IsVibrationEnabled([[maybe_unused]] const PadIdentifier& identifier) { |