Skip to content

Commit

Permalink
Add F5 as a shortcut for refreshing the display, to help with testing
Browse files Browse the repository at this point in the history
  • Loading branch information
joeraz committed Sep 18, 2024
1 parent 83baa54 commit 57adebf
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions html-src/howtoplay.html
Original file line number Diff line number Diff line change
Expand Up @@ -129,4 +129,5 @@ <h2>Undocumented key bindings</h2>
<li> <i>Ctrl-I</i> - Change table tile
<li> <i>Ctrl-U</i> - Play the next music song
<li> <i>Ctrl-W</i> - Select game, using old game select window
<li> <i>F5</i> - Refresh the game layout
</ul>
8 changes: 8 additions & 0 deletions pysollib/ui/tktile/menubar.py
Original file line number Diff line number Diff line change
Expand Up @@ -994,6 +994,8 @@ def _createMenubar(self):
self._bindKey(ctrl, "Up", self.mSelectPrevGameById)
self._bindKey(ctrl, "Down", self.mSelectNextGameById)

self._bindKey("", "F5", self.refresh)

if os.name == 'posix' and platform.system() != 'Darwin':
self._bindKey('Alt-', 'F4', self.mQuit)

Expand Down Expand Up @@ -2024,6 +2026,12 @@ def mOptNegativeBottom(self, *event):
self.game.endGame(bookmark=1)
self.game.quitGame(bookmark=1)

def refresh(self, *event):
self.app.updateCardset()
self.game.endGame(bookmark=1)
self.game.quitGame(bookmark=1)


#
# toolbar support
#
Expand Down

0 comments on commit 57adebf

Please sign in to comment.