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
This commit is contained in:
baby.lueshi 2011-07-13 05:53:56 +00:00
parent bb827eb837
commit 2eb1565aaa
3 changed files with 7 additions and 1 deletions

View File

@ -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

View File

@ -368,3 +368,8 @@ void TASInputDlg::OnCloseWindow(wxCloseEvent& event)
ResetValues();
}
}
bool TASInputDlg::HasFocus()
{
return (wxWindow::FindFocus() == this || wxWindow::FindFocus()->GetParent() == this);
}

View File

@ -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;