From 73427217159147a7a89c9ea7e23899653aec835e Mon Sep 17 00:00:00 2001 From: Daniel Weschke Date: Tue, 13 Apr 2021 12:47:52 +0200 Subject: [PATCH] add config parameter for the gui url --- controldeck_gui.py | 3 ++- example/controldeck.conf | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/controldeck_gui.py b/controldeck_gui.py index 81987d7..1ee9b28 100644 --- a/controldeck_gui.py +++ b/controldeck_gui.py @@ -8,6 +8,7 @@ def main(): controldeck.process("controldeck &", output=False) config = controldeck.config_load() + url = config.get('gui', 'url', fallback='http://0.0.0.0:8000') + "/?gui" try: width = int(config.get('gui', 'width', fallback=800)) except ValueError as e: @@ -46,7 +47,7 @@ def main(): on_top = config.get('gui', 'always_on_top', fallback='False').title() == 'True' create_window("ControlDeck", - url="http://0.0.0.0:8000/?gui", + url=url, html=None, js_api=None, width=width, diff --git a/example/controldeck.conf b/example/controldeck.conf index 3eb45f0..eddbe60 100644 --- a/example/controldeck.conf +++ b/example/controldeck.conf @@ -67,6 +67,7 @@ # mic-mute-image-alt = [gui] +url = http://0.0.0.0:8000 width = 800 height = 600 # x and y specifying the window coordinate (empty = centered)