Skip to content

Commit f25f486

Browse files
Mark default drum and pattern constants as translatable (#113) (#122)
Co-authored-by: aaroncocker <me@aaroncocker.org.uk>
1 parent 404cdff commit f25f486

1 file changed

Lines changed: 21 additions & 16 deletions

File tree

src/config/constants.py

Lines changed: 21 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -18,27 +18,32 @@
1818
# SPDX-License-Identifier: GPL-3.0-or-later
1919

2020
from typing import List, Set, Tuple
21+
from gettext import gettext as _
2122

23+
# Default drum part names shown in the UI
2224
DEFAULT_DRUM_PARTS: List[str] = [
23-
"kick",
24-
"kick-2",
25-
"kick-3",
26-
"snare",
27-
"snare-2",
28-
"hihat",
29-
"hihat-2",
30-
"clap",
31-
"tom",
32-
"crash",
25+
_("kick"),
26+
_("kick-2"),
27+
_("kick-3"),
28+
_("snare"),
29+
_("snare-2"),
30+
_("hihat"),
31+
_("hihat-2"),
32+
_("clap"),
33+
_("tom"),
34+
_("crash"),
3335
]
36+
37+
# Default rhythm pattern names shown in the UI
3438
DEFAULT_PATTERNS: List[str] = [
35-
"Shoot",
36-
"Maybe Rock",
37-
"Boom Boom",
38-
"Night",
39-
"Slow",
40-
"Chill",
39+
_("Shoot"),
40+
_("Maybe Rock"),
41+
_("Boom Boom"),
42+
_("Night"),
43+
_("Slow"),
44+
_("Chill"),
4145
]
46+
4247
NUM_TOGGLES: int = 16
4348
GROUP_TOGGLE_COUNT: int = 4
4449
DEFAULT_BPM: int = 120

0 commit comments

Comments
 (0)