Volume level for player

This commit is contained in:
localhost_frssoft 2022-11-15 02:02:22 +03:00
parent eac531c373
commit 5556a0c3de
3 changed files with 3 additions and 0 deletions

View file

@ -82,6 +82,7 @@ radio_event_gen = threading.Event()
@logger.catch @logger.catch
def radio_load(id_radio=None, type_radio='custom', name=None, related_object=None): def radio_load(id_radio=None, type_radio='custom', name=None, related_object=None):
show_like_button = get_config('show_like_button') show_like_button = get_config('show_like_button')
player.volume = get_config('mpv_volume')
requested_radio = { requested_radio = {
'custom_radio': id_radio, 'custom_radio': id_radio,
'radio_type': type_radio, 'radio_type': type_radio,

View file

@ -24,6 +24,7 @@ def set_http_header(headers=[]):
@logger.catch @logger.catch
def player_menu(header='', storage={}): def player_menu(header='', storage={}):
player_fw_storage.storage = storage player_fw_storage.storage = storage
player.volume = get_config("mpv_volume")
while True: while True:
try: try:
player_items_menu = ['Next', 'Prev', 'Pause', player_items_menu = ['Next', 'Prev', 'Pause',

View file

@ -39,6 +39,7 @@ default_conf = {
"shitnoise.monster" "shitnoise.monster"
], ],
'prefetch_playlist': True, 'prefetch_playlist': True,
'mpv_volume': 100,
'show_like_button': True, 'show_like_button': True,
'show_artist_name_in_albums': False 'show_artist_name_in_albums': False
} }