followup on kbd trans issues fix in 30b92724

Use the table to to replace both the translated string and the English
string.

Signed-off-by: Rafael Kitover <rkitover@gmail.com>
This commit is contained in:
Rafael Kitover 2019-07-03 02:17:13 +00:00
parent eaf1ad2429
commit d585a61049
No known key found for this signature in database
GPG Key ID: 08AB596679D86240
1 changed files with 6 additions and 1 deletions

View File

@ -138,12 +138,17 @@ wxString wxKeyTextCtrl::ToString(int mod, int key)
int keys_el_size = sizeof(keys_with_display_names)/sizeof(keys_with_display_names[0]);
for (int i = 0; i < keys_el_size; i++) {
wxString name_tr(_(keys_with_display_names[i].name));
wxString display_name_tr(_(keys_with_display_names[i].display_name));
name_tr.MakeUpper();
display_name_tr.MakeUpper();
wxString name(_(keys_with_display_names[i].name));
wxString display_name(_(keys_with_display_names[i].display_name));
name.MakeUpper();
display_name.MakeUpper();
s.Replace(display_name, name, true);
s.Replace(display_name_tr, name_tr, true);
s.Replace(display_name, name, true);
}
return s;