Skip to content

Commit

Permalink
Disable keyrepeat for shortcuts
Browse files Browse the repository at this point in the history
Currently the keyboard shortcut actions gets repeated when holding down the shortcut keys. I don't think this is intentional as I didn't find any shortcuts that would benefit from this behavior. 

Besides just being a bit annoying, this could also lead to crashes as the program would get into an undefined state.

For example if you held down the crop shortcut key (shift + c) and clicked outside of the crop hot zones, beeref would crash most of the time.
  • Loading branch information
DarkDefender authored and rbreu committed Jun 2, 2024
1 parent 6e3bc35 commit c545ad6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions beeref/actions/mixin.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ def _init_action_checkable(self, actiondef, qaction):
def _create_actions(self):
for action in actions.values():
qaction = QtGui.QAction(action.text, self)
qaction.setAutoRepeat(False)
shortcuts = action.get_shortcuts()
if shortcuts:
qaction.setShortcuts(shortcuts)
Expand Down

0 comments on commit c545ad6

Please sign in to comment.