Compare commits

...

2 Commits

Author SHA1 Message Date
Bernd
9c7fe0c32d fixing building instructions 2025-08-06 13:40:43 +05:00
Bernd
4c3265242d changing key shortcuts for tab navigation 2025-08-06 13:33:29 +05:00
2 changed files with 11 additions and 12 deletions

View File

@ -64,7 +64,6 @@ class AnimeDialog(QDialog):
self.name_edit.setText(html.unescape(entry[1])) self.name_edit.setText(html.unescape(entry[1]))
self.year_spin.setValue(entry[2]) self.year_spin.setValue(entry[2])
self.season_combo.setCurrentText((entry[3] or "Other").capitalize()) self.season_combo.setCurrentText((entry[3] or "Other").capitalize())
print("entry[3] = " + entry[3])
self.status_combo.setCurrentText(entry[4]) self.status_combo.setCurrentText(entry[4])
self.type_combo.setCurrentText(entry[5] or '') self.type_combo.setCurrentText(entry[5] or '')
self.comment_edit.setPlainText(html.unescape(entry[6] or '')) self.comment_edit.setPlainText(html.unescape(entry[6] or ''))
@ -111,8 +110,8 @@ class ShortcutsDialog(QDialog):
shortcuts_text.setPlainText(""" shortcuts_text.setPlainText("""
Global Shortcuts: Global Shortcuts:
- A: Add an anime - A: Add an anime
- Page Down: Next tab - Ctrl + Page Down: Next tab
- Page Up: Previous tab - Ctrl + Page Up: Previous tab
- Ctrl + Q: Quit the program - Ctrl + Q: Quit the program
- R: Pick random anime - R: Pick random anime
- Ctrl + + : Increase table scale - Ctrl + + : Increase table scale
@ -820,14 +819,6 @@ class AnimeTracker(QMainWindow):
if modifiers == Qt.NoModifier: if modifiers == Qt.NoModifier:
if key == Qt.Key_A: if key == Qt.Key_A:
self.add_anime() self.add_anime()
elif key == Qt.Key_PageDown:
current = self.tab_widget.currentIndex()
if current < self.tab_widget.count() - 1:
self.tab_widget.setCurrentIndex(current + 1)
elif key == Qt.Key_PageUp:
current = self.tab_widget.currentIndex()
if current > 0:
self.tab_widget.setCurrentIndex(current - 1)
elif key == Qt.Key_R: elif key == Qt.Key_R:
self.random_pick() self.random_pick()
elif key == Qt.Key_Q: elif key == Qt.Key_Q:
@ -846,6 +837,14 @@ class AnimeTracker(QMainWindow):
self.set_current_tab_by_identifier(current_id) self.set_current_tab_by_identifier(current_id)
elif key == Qt.Key_Q: elif key == Qt.Key_Q:
self.close() self.close()
elif key == Qt.Key_PageDown:
current = self.tab_widget.currentIndex()
if current < self.tab_widget.count() - 1:
self.tab_widget.setCurrentIndex(current + 1)
elif key == Qt.Key_PageUp:
current = self.tab_widget.currentIndex()
if current > 0:
self.tab_widget.setCurrentIndex(current - 1)
super().keyPressEvent(event) super().keyPressEvent(event)

View File

@ -11,7 +11,7 @@ Then run a binary:
`./dist/AnimeTracker/AnimeTracker` `./dist/AnimeTracker/AnimeTracker`
## How to update the binary file ## How to update the binary file
cp ~/Documents/programs/python/anime-tracker/dist/AnimeTracker/AnimeTracker ~/Applications/AnimeTracker/AnimeTracker `rm -rf ~/Applications/AnimeTracker/AnimeTracker/_internal && cp -r ~/Documents/programs/python/anime-tracker/dist/AnimeTracker ~/Applications/AnimeTracker`
## How to run this app without building: ## How to run this app without building:
`python frontend.py` `python frontend.py`