diff options
| author | Jordan Woyak <jordan.woyak@gmail.com> | 2025-06-15 15:45:04 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-15 15:45:04 -0500 |
| commit | 28a6eb26cc2c98726c59f254e8962eb1209f5578 (patch) | |
| tree | a60a3e16e01077cfdaf80c55a41c530b1884d663 /Source/Core/InputCommon/ControllerInterface/CoreDevice.h | |
| parent | 3a94289ad6e27011fe0ca3ab0fb0fee771fb9fa8 (diff) | |
| parent | 83beebaf8b074f1c7161134065f19baea08f78a6 (diff) | |
Merge pull request #13703 from jordan-woyak/map-and-calibrate
DolphinQt/InputCommon: Make the "Calibrate" button also map inputs.
Diffstat (limited to 'Source/Core/InputCommon/ControllerInterface/CoreDevice.h')
| -rw-r--r-- | Source/Core/InputCommon/ControllerInterface/CoreDevice.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Source/Core/InputCommon/ControllerInterface/CoreDevice.h b/Source/Core/InputCommon/ControllerInterface/CoreDevice.h index 95f9f5b88e..c8be0aeb65 100644 --- a/Source/Core/InputCommon/ControllerInterface/CoreDevice.h +++ b/Source/Core/InputCommon/ControllerInterface/CoreDevice.h @@ -8,6 +8,7 @@ #include <memory> #include <mutex> #include <optional> +#include <span> #include <string> #include <string_view> #include <vector> @@ -217,6 +218,8 @@ public: Clock::time_point press_time; std::optional<Clock::time_point> release_time; ControlState smoothness = 0; + + bool IsAnalogPress() const { return smoothness > 1.00001; } }; Device::Input* FindInput(std::string_view name, const Device* def_dev) const; @@ -253,7 +256,7 @@ public: InputDetector(); ~InputDetector(); - void Start(const DeviceContainer& container, const std::vector<std::string>& device_strings); + void Start(const DeviceContainer& container, std::span<const std::string> device_strings); void Update(std::chrono::milliseconds initial_wait, std::chrono::milliseconds confirmation_wait, std::chrono::milliseconds maximum_wait); bool IsComplete() const; |
