diff --git a/src/nvda_voicemeeter/window.py b/src/nvda_voicemeeter/window.py index 9170958..7553bff 100644 --- a/src/nvda_voicemeeter/window.py +++ b/src/nvda_voicemeeter/window.py @@ -194,20 +194,26 @@ class NVDAVMWindow(psg.Window): # Strip Sliders for i in range(self.kind.num_strip): - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||FOCUS IN") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||FOCUS OUT") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY LEFT") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY RIGHT") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY SHIFT LEFT") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY SHIFT RIGHT") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY CTRL LEFT") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY CTRL RIGHT") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY UP") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY DOWN") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY SHIFT UP") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY SHIFT DOWN") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY CTRL UP") - self[f"STRIP {i}||SLIDER GAIN"].bind("", "||KEY CTRL DOWN") + for param in ("GAIN", "LIMIT"): + if self.kind.name == "basic" and param == "LIMIT": + continue + self[f"STRIP {i}||SLIDER {param}"].bind("", "||FOCUS IN") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||FOCUS OUT") + for param in util.get_slider_params(i, self.vm): + self[f"STRIP {i}||SLIDER {param}"].bind("", "||FOCUS IN") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||FOCUS OUT") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY LEFT") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY RIGHT") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY SHIFT LEFT") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY SHIFT RIGHT") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY CTRL LEFT") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY CTRL RIGHT") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY UP") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY DOWN") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY SHIFT UP") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY SHIFT DOWN") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY CTRL UP") + self[f"STRIP {i}||SLIDER {param}"].bind("", "||KEY CTRL DOWN") # Bus Params params = ["MONO", "EQ", "MUTE", "MODE"]