Skip to content

Commit a2d1dc3

Browse files
committed
- version 0.9.3.3
- resource opener window will only open on linux (et al)
1 parent eb7f5c9 commit a2d1dc3

11 files changed

+42
-14
lines changed

Changelog

+6
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
2024-04-18 s-n-g
2+
* version 0.9.3.3 (BUG FIX)
3+
* adding a resource opener parameter for linux installations
4+
* fixing issues #236 and #237
5+
* fixing several minor bugs
6+
17
2024-04-08 s-n-g
28
* version 0.9.3.2 (BUG FIX)
39
* fixing #233 (move .registers to state dir)

docs/index.html

+6
Original file line numberDiff line numberDiff line change
@@ -206,6 +206,12 @@ <h2 id="requirements">Requirements <span style="padding-left: 10px;"><sup style=
206206
<h2 id="changelog">Changelog <span style="padding-left: 10px;"><sup style="font-size: 50%"><a href="#" title="Go to top of the page">Top</a></sup></span></h2>
207207
<pre style="height: 200px;">
208208

209+
2024-04-18 s-n-g
210+
* version 0.9.3.3 (BUG FIX)
211+
* adding a resource opener parameter for linux installations
212+
* fixing issues #236 and #237
213+
* fixing several minor bugs
214+
209215
2024-04-08 s-n-g
210216
* version 0.9.3.2 (BUG FIX)
211217
* fixing #233 (move .registers to state dir)

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "pyradio"
3-
version = "0.9.3.2"
3+
version = "0.9.3.3"
44
authors = [
55
{ name="Ben Dowling", email="[email protected]" },
66
{ name="Spiros Georgaras", email="[email protected]" },

pyradio/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# -*- coding: utf-8 -*-
22
" pyradio -- Console radio player. "
33

4-
version_info = (0, 9, 3, 2)
4+
version_info = (0, 9, 3, 3)
55

66
# Set it to True if new stations have been
77
# added to the package's stations.csv

pyradio/config

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ recording_dir = default
5353
# gio, mimeopen, mimeo or handlr, in that order of detection. If none if found,
5454
# the requested file will simply not open.
5555
# To set a custom Opener, insert its name (either absolute path to its executable
56-
# or its name, if it is in your PATH), followedi by any parameter required,
56+
# or its name, if it is in your PATH), followed by any parameter required,
5757
# for example: "/usr/bin/gio open", "mimeopen -n".
5858
resource_opener = auto
5959

pyradio/config_window.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -729,7 +729,10 @@ def keypress(self, char):
729729
self._global_functions[char]()
730730

731731
elif val[0] == 'resource_opener':
732-
return self.n_u.INSERT_RESOURCE_OPENER, []
732+
if not (platform.startswith('win') or \
733+
platform.startswith('dar')):
734+
return self.n_u.INSERT_RESOURCE_OPENER, []
735+
return -1, []
733736

734737
elif val[0] == 'recording_dir':
735738
return self.n_u.INSERT_RECORDINGS_DIR_MODE, []

pyradio/edit.py

+1-6
Original file line numberDiff line numberDiff line change
@@ -1483,9 +1483,7 @@ def show(self):
14831483
self._win.addstr(16 + adjust_line_Y, 5, '?', curses.color_pair(4))
14841484
self._win.addstr(16 + adjust_line_Y, 23, 'Help or Line editor help.', curses.color_pair(5))
14851485

1486-
self._win.addstr(17 + adjust_line_Y, 5, 'h', curses.color_pair(4))
1487-
self._win.addstr(17 + adjust_line_Y, 23, 'Display HTML help (not in Line Editor).', curses.color_pair(5))
1488-
1486+
adjust_line_Y -= 1
14891487
if self.maxY > 22 + adjust_line_Y and self.maxX > 76:
14901488
try:
14911489
self._win.addstr(19 + adjust_line_Y, 5, '─' * (self.maxX - 10), curses.color_pair(12))
@@ -1633,9 +1631,6 @@ def keypress(self, char):
16331631
elif char == ord('s') and self._focus > 0:
16341632
# s, execute
16351633
return self._get_result(ret)
1636-
elif char == ord('h') and self._focus > 0:
1637-
html = HtmlHelp()
1638-
html.open_filename(a_file='rec-dir.html')
16391634
elif self._focus == 0:
16401635
"""
16411636
Returns:

pyradio/install.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
''' This is PyRadio version this
1717
install.py was released for
1818
'''
19-
PyRadioInstallPyReleaseVersion = '0.9.3.2'
19+
PyRadioInstallPyReleaseVersion = '0.9.3.3'
2020

2121
import locale
2222
locale.setlocale(locale.LC_ALL, "")

pyradio/messages_system.py

+18
Original file line numberDiff line numberDiff line change
@@ -1109,6 +1109,24 @@ def set_text(self, parent, *args):
11091109
If none of them is installed, close this window and
11101110
press |F8| to get to the player installation window.
11111111
1112+
'''
1113+
),
1114+
1115+
'M_RESOURCE_OPENER': ('Resource Opener Help',
1116+
r'''A |Resource Opener| is a program used to open files passed to it
1117+
as arguments.
1118+
1119+
|PyRadio| will use it to open either directories or HTML files.
1120+
1121+
Default value is "|auto|", in which case, |PyRadio| will try to use
1122+
|xdg-open|, |gio|, |mimeopen|, |mimeo| or |handlr|, in that order of
1123+
detection. If none if found, the requested file will simply not
1124+
open.
1125+
1126+
To set a |Custom Opener|, insert its name (either absolute path
1127+
to its executable or its name, if it is in your |PATH|), followed
1128+
by any parameter required, for example: "|/usr/bin/gio open|",
1129+
"|mimeopen -n|", "|xdg-open|".
11121130
'''
11131131
),
11141132

pyradio/radio.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -7301,11 +7301,11 @@ def keypress(self, char):
73017301
# show invalid dir message
73027302
self._show_notification_with_delay(
73037303
delay=1.5,
7304-
txt='______Invalid directory specified!!!______\n',
7304+
txt='______Invalid file specified!!!______\n',
73057305
mode_to_set=self.ws.operation_mode,
73067306
callback_function=self.refreshBody_after_Message)
73077307
elif ret == 4:
7308-
self._open_message_win_by_key('M_REC_DIR_HELP')
7308+
self._open_message_win_by_key('M_RESOURCE_OPENER')
73097309

73107310
elif self.ws.operation_mode == self.ws.INSERT_RECORDINGS_DIR_MODE:
73117311
ret, new_dir, self._asked_to_move_recordings_dir = self._insert_recording_dir_win.keypress(char)

pyradio/win.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
https://sourceforge.net/projects/mpv-player-windows/files/latest/download
3939
'''
4040
zurl = [
41-
'https://sourceforge.com/projects/mpv-player-windows/files/64bit/mpv-x86_64-20240407-git-3c1e983.7z/download',
41+
'https://sourceforge.com/projects/mpv-player-windows/files/64bit/mpv-x86_64-20240414-git-6a8b130.7z/download',
4242
'https://sourceforge.net/projects/mplayerwin/files/MPlayer-MEncoder/r38151/mplayer-svn-38151-x86_64.7z/download'
4343
]
4444

0 commit comments

Comments
 (0)