input_common: Add support for analog toggle
This commit is contained in:
parent
199f77b92f
commit
2898be69f4
4 changed files with 15 additions and 0 deletions
|
@ -52,6 +52,9 @@ Common::Input::ButtonStatus TransformToButton(const Common::Input::CallbackStatu
|
|||
Common::Input::ButtonStatus status{};
|
||||
switch (callback.type) {
|
||||
case Common::Input::InputType::Analog:
|
||||
status.value = TransformToTrigger(callback).pressed.value;
|
||||
status.toggle = callback.analog_status.properties.toggle;
|
||||
break;
|
||||
case Common::Input::InputType::Trigger:
|
||||
status.value = TransformToTrigger(callback).pressed.value;
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue