mirror of
https://github.com/onyx-and-iris/voicemeeter-compact.git
synced 2026-03-09 19:59:13 +00:00
add support for 'host' in toml vban config
fix error with VBANCMDConnectionError error dialog
This commit is contained in:
parent
81a5497a32
commit
0d04a2f33e
@ -357,15 +357,17 @@ class Menus(tk.Menu):
|
|||||||
opts = {}
|
opts = {}
|
||||||
opts |= self.vban_config[f'connection-{i + 1}']
|
opts |= self.vban_config[f'connection-{i + 1}']
|
||||||
kind_id = opts.pop('kind')
|
kind_id = opts.pop('kind')
|
||||||
|
if 'ip' in opts:
|
||||||
|
opts['host'] = opts.pop('ip')
|
||||||
self.vban = vban_cmd.api(kind_id, **opts)
|
self.vban = vban_cmd.api(kind_id, **opts)
|
||||||
# login to vban interface
|
# login to vban interface
|
||||||
try:
|
try:
|
||||||
self.logger.info(f'Attempting vban connection to {opts.get("ip")}')
|
self.logger.info(f'Attempting vban connection to {opts.get("host")}')
|
||||||
self.vban.login()
|
self.vban.login()
|
||||||
except VBANCMDConnectionError as e:
|
except VBANCMDConnectionError as e:
|
||||||
self.vban.logout()
|
self.vban.logout()
|
||||||
msg = (
|
msg = (
|
||||||
f'Timeout attempting to establish connection to {opts.get("ip")}',
|
f'Timeout attempting to establish connection to {opts.get("host")}',
|
||||||
'Please check your connection settings',
|
'Please check your connection settings',
|
||||||
)
|
)
|
||||||
messagebox.showerror('Connection Error', '\n'.join(msg))
|
messagebox.showerror('Connection Error', '\n'.join(msg))
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user