diff options
| author | Jasper St. Pierre <jstpierre@mecheye.net> | 2015-05-26 12:04:16 -0700 |
|---|---|---|
| committer | degasus <wickmarkus@web.de> | 2015-06-04 10:44:20 +0200 |
| commit | c84cefa990cd4bd8d418447e4379d223155c5e73 (patch) | |
| tree | 820a0de25701c8814a71de6a079535fe55ee0023 /Source/Core/DolphinWX/FrameTools.cpp | |
| parent | 1ed38e901ef2aebb738d2e994fea8b7b6085ec03 (diff) | |
Remove wx-based Hotkey stuff
The core InputCommon Hotkeys interface does all of this for us.
Diffstat (limited to 'Source/Core/DolphinWX/FrameTools.cpp')
| -rw-r--r-- | Source/Core/DolphinWX/FrameTools.cpp | 33 |
1 files changed, 2 insertions, 31 deletions
diff --git a/Source/Core/DolphinWX/FrameTools.cpp b/Source/Core/DolphinWX/FrameTools.cpp index 04e31fbfaf..d56a8486b2 100644 --- a/Source/Core/DolphinWX/FrameTools.cpp +++ b/Source/Core/DolphinWX/FrameTools.cpp @@ -60,7 +60,6 @@ #include "DolphinWX/Frame.h" #include "DolphinWX/GameListCtrl.h" #include "DolphinWX/Globals.h" -#include "DolphinWX/HotkeyDlg.h" #include "DolphinWX/InputConfigDiag.h" #include "DolphinWX/ISOFile.h" #include "DolphinWX/LogWindow.h" @@ -230,7 +229,6 @@ wxMenuBar* CFrame::CreateMenu() pOptionsMenu->Append(IDM_CONFIG_GFX_BACKEND, _("&Graphics Settings")); pOptionsMenu->Append(IDM_CONFIG_AUDIO, _("&Audio Settings")); pOptionsMenu->Append(IDM_CONFIG_CONTROLLERS, _("&Controller Settings")); - pOptionsMenu->Append(IDM_CONFIG_MENU_COMMANDS, _("&Key Shortcuts")); pOptionsMenu->Append(IDM_CONFIG_HOTKEYS, _("&Hotkey Settings")); if (g_pCodeWindow) { @@ -390,11 +388,7 @@ wxMenuBar* CFrame::CreateMenu() wxString CFrame::GetMenuLabel(int Id) { - int hotkey = SConfig::GetInstance().\ - m_LocalCoreStartupParameter.iHotkey[Id]; - int hotkeymodifier = SConfig::GetInstance().\ - m_LocalCoreStartupParameter.iHotkeyModifier[Id]; - wxString Hotkey, Label, Modifier; + wxString Label; switch (Id) { @@ -533,14 +527,7 @@ wxString CFrame::GetMenuLabel(int Id) Label = wxString::Format(_("Undefined %i"), Id); } - hotkeymodifier &= wxMOD_CONTROL | wxMOD_ALT | wxMOD_SHIFT; - - Modifier = WxUtils::WXKeymodToString(hotkeymodifier); - Hotkey = WxUtils::WXKeyToString(hotkey); - if (Modifier.Len() + Hotkey.Len() > 0) - Label += '\t'; - - return Label + Modifier + Hotkey; + return Label; } @@ -1059,8 +1046,6 @@ void CFrame::StartGame(const std::string& filename) m_RenderParent->SetFocus(); - wxTheApp->Bind(wxEVT_KEY_DOWN, &CFrame::OnKeyDown, this); - wxTheApp->Bind(wxEVT_KEY_UP, &CFrame::OnKeyUp, this); wxTheApp->Bind(wxEVT_RIGHT_DOWN, &CFrame::OnMouse, this); wxTheApp->Bind(wxEVT_RIGHT_UP, &CFrame::OnMouse, this); wxTheApp->Bind(wxEVT_MIDDLE_DOWN, &CFrame::OnMouse, this); @@ -1222,10 +1207,6 @@ void CFrame::OnStopped() // Destroy the renderer frame when not rendering to main m_RenderParent->Unbind(wxEVT_SIZE, &CFrame::OnRenderParentResize, this); - // Keyboard - wxTheApp->Unbind(wxEVT_KEY_DOWN, &CFrame::OnKeyDown, this); - wxTheApp->Unbind(wxEVT_KEY_UP, &CFrame::OnKeyUp, this); - // Mouse wxTheApp->Unbind(wxEVT_RIGHT_DOWN, &CFrame::OnMouse, this); wxTheApp->Unbind(wxEVT_RIGHT_UP, &CFrame::OnMouse, this); @@ -1340,16 +1321,6 @@ void CFrame::OnConfigControllers(wxCommandEvent& WXUNUSED (event)) config_dlg.ShowModal(); } -void CFrame::OnConfigMenuCommands(wxCommandEvent& WXUNUSED(event)) -{ - HotkeyConfigDialog m_HotkeyDialog(this); - m_HotkeyDialog.ShowModal(); - - // Update the GUI in case menu accelerators were changed - UpdateGUI(); -} - - void CFrame::OnConfigHotkey(wxCommandEvent& WXUNUSED (event)) { InputConfig* const hotkey_plugin = HotkeyManagerEmu::GetConfig(); |
