diff options
author | Anton Luka Šijanec <anton@sijanec.eu> | 2022-11-12 19:07:52 +0100 |
---|---|---|
committer | Anton Luka Šijanec <anton@sijanec.eu> | 2022-11-12 19:07:52 +0100 |
commit | 4bd1446cea1fe4a86012ed9f8d16f13f9f1b3321 (patch) | |
tree | 6f303d5cac8678def93d07255558784540bb7335 /gromka/keyboard.py | |
parent | keyboard.py namesto keyboard.txt (diff) | |
download | luč-4bd1446cea1fe4a86012ed9f8d16f13f9f1b3321.tar luč-4bd1446cea1fe4a86012ed9f8d16f13f9f1b3321.tar.gz luč-4bd1446cea1fe4a86012ed9f8d16f13f9f1b3321.tar.bz2 luč-4bd1446cea1fe4a86012ed9f8d16f13f9f1b3321.tar.lz luč-4bd1446cea1fe4a86012ed9f8d16f13f9f1b3321.tar.xz luč-4bd1446cea1fe4a86012ed9f8d16f13f9f1b3321.tar.zst luč-4bd1446cea1fe4a86012ed9f8d16f13f9f1b3321.zip |
Diffstat (limited to 'gromka/keyboard.py')
-rwxr-xr-x | gromka/keyboard.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gromka/keyboard.py b/gromka/keyboard.py index 14276cc..4873636 100755 --- a/gromka/keyboard.py +++ b/gromka/keyboard.py @@ -38,7 +38,10 @@ for key in show.find_all("Input"): if key.has_attr("Universe") and key["Universe"] == "0" and key.has_attr("Channel") and int(key["Channel"]) >= 198 and int(key["Channel"]) <= 198 + 24: if midi[int(key["Channel"]) - 198] != "": midi[int(key["Channel"]) - 198] += ", " - midi[int(key["Channel"]) - 198] += key.parent["Caption"] + " (" + key.parent.name + ")" + caption = "" + if key.parent.has_attr("Caption"): + caption = key.parent["Caption"] + midi[int(key["Channel"]) - 198] += caption + " (" + key.parent.name + ")" for key in range(0, 24): kje = " zgoraj" |