diff options
| author | Lioncash <mathew1800@gmail.com> | 2016-10-18 18:09:24 -0400 |
|---|---|---|
| committer | Lioncash <mathew1800@gmail.com> | 2016-10-20 09:54:39 -0400 |
| commit | 42e1dafd6dc312d85bad2605fb494af0b7895892 (patch) | |
| tree | 99ec9a3f84c11e2c2ac2817061ff773632840203 /Source/Core/DolphinWX/Frame.cpp | |
| parent | f871b2177e727af25c451990974e3d380360dd02 (diff) | |
Frame: Rename GetCmdForHotkey to GetMenuIDFromHotkey
This more accurately describes what it's actually doing. This can also be
a local function, since it's not needed anywhere else.
Diffstat (limited to 'Source/Core/DolphinWX/Frame.cpp')
| -rw-r--r-- | Source/Core/DolphinWX/Frame.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Source/Core/DolphinWX/Frame.cpp b/Source/Core/DolphinWX/Frame.cpp index a2c7de094b..a1f5d0608f 100644 --- a/Source/Core/DolphinWX/Frame.cpp +++ b/Source/Core/DolphinWX/Frame.cpp @@ -866,7 +866,7 @@ static bool IsHotkey(int id, bool held = false) return HotkeyManagerEmu::IsPressed(id, held); } -int GetCmdForHotkey(unsigned int key) +static int GetMenuIDFromHotkey(unsigned int key) { switch (key) { @@ -1288,11 +1288,11 @@ void CFrame::ParseHotkeys() if (IsHotkey(i)) { - int cmd = GetCmdForHotkey(i); - if (cmd >= 0) + const int id = GetMenuIDFromHotkey(i); + if (id >= 0) { - wxCommandEvent evt(wxEVT_MENU, cmd); - wxMenuItem* item = GetMenuBar()->FindItem(cmd); + wxCommandEvent evt(wxEVT_MENU, id); + wxMenuItem* item = GetMenuBar()->FindItem(id); if (item && item->IsCheckable()) { item->wxMenuItemBase::Toggle(); |
