1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-06-25 08:38:39 +02:00

Fix for problem with the handling of default keystrokes.

In the class CommandListEntry, the default key was being set to an empty string, rather than the correct key.
This resulted in bugs such as: pressing default in keyboard preferences clearing all the shortcuts, entries
being created in audacity.cfg for all commands with keystrokes, and ending up with commands with the same shortcut.
This commit is contained in:
David Bailes 2015-08-26 11:44:50 +01:00
parent 133c0ec61d
commit e8a07c61e2

View File

@ -856,10 +856,10 @@ CommandListEntry *CommandManager::NewIdentifier(const wxString & name,
entry->id = wxID_ABOUT; entry->id = wxID_ABOUT;
#endif #endif
entry->defaultKey = entry->key;
entry->name = name; entry->name = name;
entry->label = label; entry->label = label;
entry->key = KeyStringNormalize(accel.BeforeFirst(wxT('\t'))); entry->key = KeyStringNormalize(accel.BeforeFirst(wxT('\t')));
entry->defaultKey = entry->key;
entry->labelPrefix = labelPrefix; entry->labelPrefix = labelPrefix;
entry->labelTop = wxMenuItem::GetLabelText(mCurrentMenuName); entry->labelTop = wxMenuItem::GetLabelText(mCurrentMenuName);
entry->menu = menu; entry->menu = menu;