Skip to content

Commit

Permalink
fix another slider bug.
Browse files Browse the repository at this point in the history
  • Loading branch information
MyreMylar committed Feb 1, 2022
1 parent 297710c commit 6d6ee6d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions docs/source/change_list.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ A record of changes between versions of Pygame GUI.

--------

**Version 0.6.4**
-----------------------------------------------------------------

Actually fix the slider this time...

**Version 0.6.3**
-----------------------------------------------------------------

Expand Down
2 changes: 1 addition & 1 deletion pygame_gui/elements/ui_horizontal_slider.py
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ def process_event(self, event: pygame.event.Event) -> bool:
if event.type == UI_BUTTON_PRESSED:
if (event.ui_element in [self.left_button, self.right_button] and
self.button_held_repeat_acc < self.button_held_repeat_time and
(self.value_range[0] < self.get_current_value() < self.value_range[1])):
(self.value_range[0] <= self.get_current_value() <= self.value_range[1])):
old_value = self.get_current_value()
new_value = (old_value - self.increment if event.ui_element == self.left_button
else old_value + self.increment)
Expand Down

0 comments on commit 6d6ee6d

Please sign in to comment.