Skip to content

Commit

Permalink
Revert "Fix vjoy activation condition handling"
Browse files Browse the repository at this point in the history
This reverts commit acf86c8.
  • Loading branch information
edwardwbarber committed Jul 12, 2022
1 parent acf86c8 commit 643814e
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions gremlin/ui/activation_condition.py
Original file line number Diff line number Diff line change
Expand Up @@ -624,6 +624,14 @@ def _modify_vjoy(self, data):
self.condition_data.vjoy_id = data["device_id"]
self.condition_data.input_type = data["input_type"]
self.condition_data.input_id = data["input_id"]

if data["input_type"] == InputType.JoystickAxis:
self.condition_data.comparison = "inside"
elif data["input_type"] == InputType.JoystickButton:
self.condition_data.comparison = "pressed"
elif data["input_type"] == InputType.JoystickHat:
self.condition_data.comparison = \
util.hat_tuple_to_direction((0, 0))
self._create_ui()

def _range_lower_changed_cb(self, value):
Expand Down

0 comments on commit 643814e

Please sign in to comment.