1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-11-23 17:30:17 +01:00

Construct MenuItem with untranslated label, so it can be static...

... and other storage of TranslatableString instead of naked wxString, for
management of menu items, in CommandManager
This commit is contained in:
Paul Licameli
2019-01-09 15:26:32 -05:00
parent aac50ae36e
commit a8de4d9e50
21 changed files with 122 additions and 124 deletions

View File

@@ -635,7 +635,7 @@ KeyView::UpdateHScroll()
void
KeyView::RefreshBindings(const CommandIDs & names,
const wxArrayString & categories,
const wxArrayString & prefixes,
const TranslatableStrings & prefixes,
const wxArrayString & labels,
const std::vector<NormalizedKeyString> & keys,
bool bSort
@@ -665,7 +665,7 @@ KeyView::RefreshBindings(const CommandIDs & names,
// Remove any menu code from the category and prefix
wxString cat = wxMenuItem::GetLabelText(categories[i]);
wxString pfx = wxMenuItem::GetLabelText(prefixes[i]);
wxString pfx = wxMenuItem::GetLabelText(prefixes[i].Translation());
// Append "Menu" this node is for a menu title
if (cat != wxT("Command"))

View File

@@ -83,7 +83,7 @@ public:
void RefreshBindings(const CommandIDs & names,
const wxArrayString & categories,
const wxArrayString & prefixes,
const TranslatableStrings & prefixes,
const wxArrayString & labels,
const std::vector<NormalizedKeyString> & keys,
bool bSort);