mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 22:12:21 -04:00
Update _load_flags to use the default_flag_names dict
This commit is contained in:
parent
89808a10b1
commit
caa8fea94b
1 changed files with 7 additions and 7 deletions
|
@ -84,49 +84,49 @@ class FlagManager:
|
||||||
self._flags = [
|
self._flags = [
|
||||||
Flag(
|
Flag(
|
||||||
1,
|
1,
|
||||||
labels["1"] if "1" in labels else tr.actions_flag_red(),
|
labels["1"] if "1" in labels else self.default_flag_names[1],
|
||||||
icon.with_color(colors.FLAG_1),
|
icon.with_color(colors.FLAG_1),
|
||||||
SearchNode(flag=SearchNode.FLAG_RED),
|
SearchNode(flag=SearchNode.FLAG_RED),
|
||||||
"actionRed_Flag",
|
"actionRed_Flag",
|
||||||
),
|
),
|
||||||
Flag(
|
Flag(
|
||||||
2,
|
2,
|
||||||
labels["2"] if "2" in labels else tr.actions_flag_orange(),
|
labels["2"] if "2" in labels else self.default_flag_names[2],
|
||||||
icon.with_color(colors.FLAG_2),
|
icon.with_color(colors.FLAG_2),
|
||||||
SearchNode(flag=SearchNode.FLAG_ORANGE),
|
SearchNode(flag=SearchNode.FLAG_ORANGE),
|
||||||
"actionOrange_Flag",
|
"actionOrange_Flag",
|
||||||
),
|
),
|
||||||
Flag(
|
Flag(
|
||||||
3,
|
3,
|
||||||
labels["3"] if "3" in labels else tr.actions_flag_green(),
|
labels["3"] if "3" in labels else self.default_flag_names[3],
|
||||||
icon.with_color(colors.FLAG_3),
|
icon.with_color(colors.FLAG_3),
|
||||||
SearchNode(flag=SearchNode.FLAG_GREEN),
|
SearchNode(flag=SearchNode.FLAG_GREEN),
|
||||||
"actionGreen_Flag",
|
"actionGreen_Flag",
|
||||||
),
|
),
|
||||||
Flag(
|
Flag(
|
||||||
4,
|
4,
|
||||||
labels["4"] if "4" in labels else tr.actions_flag_blue(),
|
labels["4"] if "4" in labels else self.default_flag_names[4],
|
||||||
icon.with_color(colors.FLAG_4),
|
icon.with_color(colors.FLAG_4),
|
||||||
SearchNode(flag=SearchNode.FLAG_BLUE),
|
SearchNode(flag=SearchNode.FLAG_BLUE),
|
||||||
"actionBlue_Flag",
|
"actionBlue_Flag",
|
||||||
),
|
),
|
||||||
Flag(
|
Flag(
|
||||||
5,
|
5,
|
||||||
labels["5"] if "5" in labels else tr.actions_flag_pink(),
|
labels["5"] if "5" in labels else self.default_flag_names[5],
|
||||||
icon.with_color(colors.FLAG_5),
|
icon.with_color(colors.FLAG_5),
|
||||||
SearchNode(flag=SearchNode.FLAG_PINK),
|
SearchNode(flag=SearchNode.FLAG_PINK),
|
||||||
"actionPink_Flag",
|
"actionPink_Flag",
|
||||||
),
|
),
|
||||||
Flag(
|
Flag(
|
||||||
6,
|
6,
|
||||||
labels["6"] if "6" in labels else tr.actions_flag_turquoise(),
|
labels["6"] if "6" in labels else self.default_flag_names[6],
|
||||||
icon.with_color(colors.FLAG_6),
|
icon.with_color(colors.FLAG_6),
|
||||||
SearchNode(flag=SearchNode.FLAG_TURQUOISE),
|
SearchNode(flag=SearchNode.FLAG_TURQUOISE),
|
||||||
"actionTurquoise_Flag",
|
"actionTurquoise_Flag",
|
||||||
),
|
),
|
||||||
Flag(
|
Flag(
|
||||||
7,
|
7,
|
||||||
labels["7"] if "7" in labels else tr.actions_flag_purple(),
|
labels["7"] if "7" in labels else self.default_flag_names[7],
|
||||||
icon.with_color(colors.FLAG_7),
|
icon.with_color(colors.FLAG_7),
|
||||||
SearchNode(flag=SearchNode.FLAG_PURPLE),
|
SearchNode(flag=SearchNode.FLAG_PURPLE),
|
||||||
"actionPurple_Flag",
|
"actionPurple_Flag",
|
||||||
|
|
Loading…
Reference in a new issue