mirror of
https://github.com/onyx-and-iris/nvda-voicemeeter.git
synced 2024-11-22 10:00:46 +00:00
remove EQ button and events if kind is basic
This commit is contained in:
parent
ed5f9ae45b
commit
790ac10d4a
@ -325,12 +325,18 @@ class Builder:
|
||||
"""tab3 row represents bus composite toggle"""
|
||||
|
||||
def add_strip_outputs(layout):
|
||||
params = ["MONO", "EQ", "MUTE", "MODE"]
|
||||
if self.vm.kind.name == "basic":
|
||||
params.remove("EQ")
|
||||
label = {"MODE": "BUSMODE"}
|
||||
layout.append(
|
||||
[
|
||||
psg.Button("Mono", size=(6, 2), key=f"BUS {i}||MONO"),
|
||||
psg.Button("EQ", size=(6, 2), key=f"BUS {i}||EQ"),
|
||||
psg.Button("Mute", size=(6, 2), key=f"BUS {i}||MUTE"),
|
||||
psg.Button(f"BUSMODE", size=(12, 2), key=f"BUS {i}||MODE"),
|
||||
psg.Button(
|
||||
label.get(param, param.capitalize()),
|
||||
size=(12 if param == "MODE" else 6, 2),
|
||||
key=f"BUS {i}||{param}",
|
||||
)
|
||||
for param in params
|
||||
]
|
||||
)
|
||||
|
||||
|
@ -185,8 +185,11 @@ class NVDAVMWindow(psg.Window):
|
||||
self[f"STRIP {i}||{param}"].bind("<Return>", "||KEY ENTER")
|
||||
|
||||
# Bus Params
|
||||
params = ["MONO", "EQ", "MUTE", "MODE"]
|
||||
if self.vm.kind.name == "basic":
|
||||
params.remove("EQ")
|
||||
for i in range(self.kind.num_bus):
|
||||
for param in ("MONO", "EQ", "MUTE", "MODE"):
|
||||
for param in params:
|
||||
self[f"BUS {i}||{param}"].bind("<FocusIn>", "||FOCUS IN")
|
||||
self[f"BUS {i}||{param}"].bind("<Return>", "||KEY ENTER")
|
||||
|
||||
@ -583,7 +586,7 @@ class NVDAVMWindow(psg.Window):
|
||||
f"{label} bus {param} {'on' if val else 'off'}",
|
||||
)
|
||||
case "MODE":
|
||||
bus_modes = get_bus_modes()
|
||||
bus_modes = get_bus_modes(self.vm)
|
||||
next_index = bus_modes.index(val) + 1
|
||||
if next_index == len(bus_modes):
|
||||
next_index = 0
|
||||
|
Loading…
Reference in New Issue
Block a user