diff options
| author | baby.lueshi <baby.lueshi@gmail.com> | 2011-07-13 05:53:56 +0000 |
|---|---|---|
| committer | baby.lueshi <baby.lueshi@gmail.com> | 2011-07-13 05:53:56 +0000 |
| commit | 2eb1565aaac9b8196fd0361c9394e8cd12afade2 (patch) | |
| tree | 9e60c0985892ff3b0237d4840387ef02ba9237d1 /Source/Core | |
| parent | bb827eb8379ecdd34bddf60d173dcec30e4b832b (diff) | |
Fixed hotkeys not working with the TAS Input dialog open.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7676 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core')
| -rw-r--r-- | Source/Core/DolphinWX/Src/Frame.cpp | 2 | ||||
| -rw-r--r-- | Source/Core/DolphinWX/Src/TASInputDlg.cpp | 5 | ||||
| -rw-r--r-- | Source/Core/DolphinWX/Src/TASInputDlg.h | 1 |
3 files changed, 7 insertions, 1 deletions
diff --git a/Source/Core/DolphinWX/Src/Frame.cpp b/Source/Core/DolphinWX/Src/Frame.cpp index 4d29350744..87eef2fa7c 100644 --- a/Source/Core/DolphinWX/Src/Frame.cpp +++ b/Source/Core/DolphinWX/Src/Frame.cpp @@ -864,7 +864,7 @@ void TASManipFunction(SPADStatus *PadStatus, int controllerID) void CFrame::OnKeyDown(wxKeyEvent& event) { if(Core::GetState() != Core::CORE_UNINITIALIZED && - RendererHasFocus()) + (RendererHasFocus() || g_TASInputDlg->HasFocus())) { int WiimoteId = -1; // Toggle fullscreen diff --git a/Source/Core/DolphinWX/Src/TASInputDlg.cpp b/Source/Core/DolphinWX/Src/TASInputDlg.cpp index 0da301176f..689681d199 100644 --- a/Source/Core/DolphinWX/Src/TASInputDlg.cpp +++ b/Source/Core/DolphinWX/Src/TASInputDlg.cpp @@ -368,3 +368,8 @@ void TASInputDlg::OnCloseWindow(wxCloseEvent& event) ResetValues(); } } + +bool TASInputDlg::HasFocus() +{ + return (wxWindow::FindFocus() == this || wxWindow::FindFocus()->GetParent() == this); +} diff --git a/Source/Core/DolphinWX/Src/TASInputDlg.h b/Source/Core/DolphinWX/Src/TASInputDlg.h index 1115a2bc8a..b65f4c9bf5 100644 --- a/Source/Core/DolphinWX/Src/TASInputDlg.h +++ b/Source/Core/DolphinWX/Src/TASInputDlg.h @@ -39,6 +39,7 @@ class TASInputDlg : public wxDialog void UpdateFromText(wxCommandEvent& event); void ResetValues(); void GetValues(SPADStatus *PadStatus, int controllerID); + bool HasFocus(); private: u8 mainX, mainY, cX, cY, lTrig, rTrig; |
