From 9cc244e9130f441c2ef1cb2550d7e97188999139 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Fri, 10 Apr 2015 19:30:54 -0400 Subject: [PATCH] HotkeyDlg: Get rid of application-wide event bindings. This dialog is used as a modal dialog, so making the key-press event bindings application-wide is unnecessary. --- Source/Core/DolphinWX/HotkeyDlg.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/Core/DolphinWX/HotkeyDlg.cpp b/Source/Core/DolphinWX/HotkeyDlg.cpp index 8eb51c430c..52cd33cb47 100644 --- a/Source/Core/DolphinWX/HotkeyDlg.cpp +++ b/Source/Core/DolphinWX/HotkeyDlg.cpp @@ -57,7 +57,7 @@ void HotkeyConfigDialog::SaveButtonMapping(int Id, int Key, int Modkey) void HotkeyConfigDialog::EndGetButtons() { - wxTheApp->Unbind(wxEVT_KEY_DOWN, &HotkeyConfigDialog::OnKeyDown, this); + Unbind(wxEVT_KEY_DOWN, &HotkeyConfigDialog::OnKeyDown, this); m_ButtonMappingTimer.Stop(); GetButtonWaitingTimer = 0; GetButtonWaitingID = 0; @@ -171,7 +171,7 @@ void HotkeyConfigDialog::OnButtonClick(wxCommandEvent& event) if (m_ButtonMappingTimer.IsRunning()) return; - wxTheApp->Bind(wxEVT_KEY_DOWN, &HotkeyConfigDialog::OnKeyDown, this); + Bind(wxEVT_KEY_DOWN, &HotkeyConfigDialog::OnKeyDown, this); // Get the button ClickedButton = (wxButton *)event.GetEventObject();