Skip to content

Commit

Permalink
Merge pull request #1405 from otseng/main
Browse files Browse the repository at this point in the history
Ver 35.24; Add shortcut to toggle audio toolbar
  • Loading branch information
eliranwong authored Dec 25, 2023
2 parents fd84836 + a3d67c9 commit 76fa729
Show file tree
Hide file tree
Showing 9 changed files with 30 additions and 9 deletions.
2 changes: 1 addition & 1 deletion UniqueBibleAppVersion.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
35.23
35.24
2 changes: 1 addition & 1 deletion docker_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ click==8.0.3
cobble==0.1.3
colorama==0.4.4
contextlib2==0.6.0.post1
cryptography==41.0.4
cryptography==41.0.6
Deprecated==1.2.13
diff-match-patch==20200713
distlib==0.3.4
Expand Down
12 changes: 12 additions & 0 deletions gui/MainWindow.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,14 @@ def toggleAudioPlayer(self):
else:
self.thirdToolBar.show()

def hideAudioPlayer(self):
if hasattr(self, "thirdToolBar"):
self.thirdToolBar.hide()

def showAudioPlayer(self):
if hasattr(self, "thirdToolBar"):
self.thirdToolBar.show()

def resizeAudioPlayer(self):
config.maximiseMediaPlayerUI = not config.maximiseMediaPlayerUI
self.setupMenuLayout(config.menuLayout)
Expand Down Expand Up @@ -994,6 +1002,10 @@ def saveMarkdown(self, view="main"):

# Command Prompt
def commandPrompt(self, prefix):
if prefix.startswith("online:::"):
self.focusCommandLineField()
self.textCommandLineEdit.setText(prefix)
return
suffix, ok = QInputDialog.getText(self, "Unique Bible App",
config.thisTranslation["enter_text_here"], QLineEdit.Normal,
"")
Expand Down
2 changes: 1 addition & 1 deletion gui/MaterialMainWindow.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def setApplicationIconSubmenu():
("menu2_topOnly", self.hideShowAdditionalToolBar, sc.hideShowAdditionalToolBar),
("menu2_top", self.hideShowMainToolBar, sc.hideShowMainToolBar),
("menu2_second", self.hideShowSecondaryToolBar, sc.hideShowSecondaryToolBar),
("menu11_audio", self.toggleAudioPlayer, None),
("menu11_audio", self.toggleAudioPlayer, sc.hideShowAudioToolBar),
("menu2_left", self.hideShowLeftToolBar, sc.hideShowLeftToolBar),
("menu2_right", self.hideShowRightToolBar, sc.hideShowRightToolBar),
)
Expand Down
3 changes: 3 additions & 0 deletions latest_changes.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
Changes in 35.24:
* Add shortcut to toggle audio toolbar

Changes in 35.23:
* specify openai package version

Expand Down
12 changes: 6 additions & 6 deletions patches.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1303,7 +1303,6 @@
(34.07, "file", "gui/WebEngineView.py")
(34.08, "file", "plugins/menu/ToDo.py")
(34.10, "file", "main.py")
(34.14, "file", "util/ShortcutUtil.py")
(34.15, "file", "util/PydubUtil.py")
(34.16, "file", "htmlResources/material/device/mobiledata_off/materialiconsoutlined/48dp/2x/outline_mobiledata_off_black_48dp.png")
(34.16, "file", "htmlResources/material/communication/import_export/materialiconsoutlined/48dp/2x/outline_import_export_black_48dp.png")
Expand Down Expand Up @@ -1345,7 +1344,6 @@
(34.79, "file", "llama_index/NET_md_index/index_store.json")
(34.79, "file", "llama_index/NET_md_index/vector_store.json")
(34.81, "file", "gui/SearchLauncher.py")
(34.82, "file", "gui/MaterialMainWindow.py")
(34.85, "file", "db/AGBTSData.py")
(34.87, "file", "util/AGBsubheadings.py")
(34.88, "file", "util/RemoteHttpHandler.py")
Expand All @@ -1367,7 +1365,6 @@
(34.95, "file", "lang/language_ru.py")
(34.95, "file", "lang/language_zh_HANS.py")
(34.95, "file", "lang/language_zh_HANT.py")
(34.97, "file", "gui/MainWindow.py")
(34.98, "file", "plugins/chatGPT/integrate google searches.py")
(35.01, "file", "plugins/chatGPT/000_UBA.py")
(35.05, "file", "plugins/chatGPT/execute python code.py")
Expand All @@ -1390,6 +1387,9 @@
(35.22, "file", "util/LocalCliHandler.py")
(35.22, "file", "util/TextCommandParser.py")
(35.23, "file", "util/checkup.py")
(35.23, "file", "UniqueBibleAppVersion.txt")
(35.23, "file", "latest_changes.txt")
(35.23, "file", "patches.txt")
(35.24, "file", "gui/MainWindow.py")
(35.24, "file", "gui/MaterialMainWindow.py")
(35.24, "file", "util/ShortcutUtil.py")
(35.24, "file", "patches.txt")
(35.24, "file", "UniqueBibleAppVersion.txt")
(35.24, "file", "latest_changes.txt")
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,4 @@ python-vlc
yt-dlp
apsw
pydnsbl
prompt_toolkit
1 change: 1 addition & 0 deletions tests/TextCommandParser_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
config.noQt = True
config.parseClearSpecialCharacters = True

from prompt_toolkit.input import create_input
from util.TextCommandParser import TextCommandParser

class TextCommandParserTestCase(unittest.TestCase):
Expand Down
4 changes: 4 additions & 0 deletions util/ShortcutUtil.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ class ShortcutUtil:
"hideShowMainToolBar": "",
"hideShowRightToolBar": "",
"hideShowSecondaryToolBar": "",
"hideShowAudioToolBar": "",
"largerFont": "",
"leftHalfScreenWidth": "",
"loadRunMacro": "",
Expand Down Expand Up @@ -215,6 +216,7 @@ class ShortcutUtil:
"hideShowMainToolBar": "Ctrl+T, 1",
"hideShowRightToolBar": "Ctrl+T, R",
"hideShowSecondaryToolBar": "Ctrl+T, 3",
"hideShowAudioToolBar": "Ctrl+T, 4",
"largerFont": "Ctrl++",
"leftHalfScreenWidth": "Ctrl+S, 3",
"loadRunMacro": "",
Expand Down Expand Up @@ -366,6 +368,7 @@ class ShortcutUtil:
"hideShowMainToolBar": '',
"hideShowRightToolBar": '',
"hideShowSecondaryToolBar": '',
"hideShowAudioToolBar": "",
"largerFont": 'Ctrl++',
"leftHalfScreenWidth": 'Ctrl+S, 3',
"loadRunMacro": '',
Expand Down Expand Up @@ -517,6 +520,7 @@ class ShortcutUtil:
"hideShowMainToolBar": "Ctrl+T, 1",
"hideShowRightToolBar": "Ctrl+T, R",
"hideShowSecondaryToolBar": "Ctrl+T, 3",
"hideShowAudioToolBar": "Ctrl+T, 4",
"largerFont": "Ctrl++",
"leftHalfScreenWidth": "Ctrl+W, L",
"loadRunMacro": "Ctrl+M",
Expand Down

0 comments on commit 76fa729

Please sign in to comment.