CFrame: Only re-assign focus when "Render to main" is enabled.

It may cause fullscreen loops and since m_RenderFrame == m_RenderParent now it's not necessary to re-assign focus anymore.
This commit is contained in:
Jules Blok 2014-08-01 21:31:17 +02:00
parent 0380bb61fa
commit b6e7e0d57f
1 changed files with 5 additions and 2 deletions

View File

@ -479,11 +479,14 @@ void CFrame::OnActive(wxActivateEvent& event)
{
if (event.GetActive() && event.GetEventObject() == m_RenderFrame)
{
if (SConfig::GetInstance().m_LocalCoreStartupParameter.bRenderToMain)
{
#ifdef __WXMSW__
::SetFocus((HWND)m_RenderParent->GetHandle());
#else
m_RenderParent->SetFocus();
#endif
}
if (SConfig::GetInstance().m_LocalCoreStartupParameter.bHideCursor &&
Core::GetState() == Core::CORE_RUN)