diff options
author | liamwhite <liamwhite@users.noreply.github.com> | 2023-01-24 09:29:37 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-24 09:29:37 -0500 |
commit | a68af583ea378b48e2ed5a19f519a815ba89e40f (patch) | |
tree | 2983c14a7d4bc2797259c7d97462a439bec629f3 /src/yuzu/configuration/configure_ringcon.h | |
parent | f99f618d45ad862c4bc23fc28c91d1c48218a3cb (diff) | |
parent | d9ee7c32975bb8d840cf93a086d6b4be39d7bfd2 (diff) |
Merge pull request #9492 from german77/joycon_release
Input_common: Implement custom joycon driver v2
Diffstat (limited to 'src/yuzu/configuration/configure_ringcon.h')
-rw-r--r-- | src/yuzu/configuration/configure_ringcon.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/yuzu/configuration/configure_ringcon.h b/src/yuzu/configuration/configure_ringcon.h index 38a9cb716..b23c27906 100644 --- a/src/yuzu/configuration/configure_ringcon.h +++ b/src/yuzu/configuration/configure_ringcon.h @@ -13,7 +13,7 @@ class InputSubsystem; namespace Core::HID { class HIDCore; -class EmulatedDevices; +class EmulatedController; } // namespace Core::HID namespace Ui { @@ -42,6 +42,12 @@ private: /// Restore all buttons to their default values. void RestoreDefaults(); + /// Sets current polling mode to ring input + void EnableRingController(); + + // Handles emulated controller events + void ControllerUpdate(Core::HID::ControllerTriggerType type); + /// Called when the button was pressed. void HandleClick(QPushButton* button, std::function<void(const Common::ParamPackage&)> new_input_setter, @@ -78,7 +84,11 @@ private: std::optional<std::function<void(const Common::ParamPackage&)>> input_setter; InputCommon::InputSubsystem* input_subsystem; - Core::HID::EmulatedDevices* emulated_device; + Core::HID::EmulatedController* emulated_controller; + + bool is_ring_enabled{}; + bool is_controller_set{}; + int callback_key; std::unique_ptr<Ui::ConfigureRingController> ui; }; |