mirror of
https://github.com/onyx-and-iris/voicemeeter-compact.git
synced 2026-03-12 05:09:12 +00:00
entry point now accepts an optional theme arg. this makes it easier to test forest/azure themes
This commit is contained in:
parent
9210a26de6
commit
5a693b8aaf
@ -37,7 +37,7 @@ class App(tk.Tk):
|
|||||||
)
|
)
|
||||||
return APP_cls
|
return APP_cls
|
||||||
|
|
||||||
def __init__(self, vmr):
|
def __init__(self, vmr, theme):
|
||||||
super().__init__()
|
super().__init__()
|
||||||
self.logger = logger.getChild(self.__class__.__name__)
|
self.logger = logger.getChild(self.__class__.__name__)
|
||||||
self._vmr = vmr
|
self._vmr = vmr
|
||||||
@ -201,11 +201,11 @@ class App(tk.Tk):
|
|||||||
_apps = {kind.name: App.make(kind) for kind in _kinds_all}
|
_apps = {kind.name: App.make(kind) for kind in _kinds_all}
|
||||||
|
|
||||||
|
|
||||||
def connect(kind_id: str, vmr) -> App:
|
def connect(kind_id: str, vmr, theme=None) -> App:
|
||||||
"""return App of the kind requested"""
|
"""return App of the kind requested"""
|
||||||
|
|
||||||
try:
|
try:
|
||||||
VMMIN_cls = _apps[kind_id]
|
VMMIN_cls = _apps[kind_id]
|
||||||
except KeyError:
|
except KeyError:
|
||||||
raise VMCompactError(f'Invalid kind: {kind_id}')
|
raise VMCompactError(f'Invalid kind: {kind_id}')
|
||||||
return VMMIN_cls(vmr)
|
return VMMIN_cls(vmr, theme)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user