mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-29 09:09:52 -06:00
Big restructuring of how the video plugin works. In linux and windows you shouldn't see a change in the functionality; however, there are changes in how render to main or not, and fullscreen modes, and such are handled. Input is largely restructured for the video plugin. It is now handled by the host. Keys for pausing and changing fullscreen are configurable. More will probably be later. This is probably classified as highly experimental.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5336 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -44,29 +44,7 @@ SPADInitialize *g_PADInitialize = NULL;
|
||||
// ----------------
|
||||
bool IsFocus()
|
||||
{
|
||||
#ifdef _WIN32
|
||||
HWND RenderingWindow = (g_PADInitialize) ? g_PADInitialize->hWnd : NULL;
|
||||
HWND Parent = GetParent(RenderingWindow);
|
||||
HWND TopLevel = GetParent(Parent);
|
||||
|
||||
if (GetForegroundWindow() == TopLevel || GetForegroundWindow() == RenderingWindow)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
#elif defined HAVE_X11 && HAVE_X11
|
||||
Display* GCdisplay = (Display*)g_PADInitialize->hWnd;
|
||||
Window GLWin = *(Window *)g_PADInitialize->pXWindow;
|
||||
bool bFocus = False;
|
||||
#if defined(HAVE_GTK2) && HAVE_GTK2 && defined(wxGTK)
|
||||
bFocus = (wxPanel *)g_PADInitialize->pPanel == wxWindow::FindFocus();
|
||||
#endif
|
||||
Window FocusWin;
|
||||
int Revert;
|
||||
XGetInputFocus(GCdisplay, &FocusWin, &Revert);
|
||||
return (GLWin == FocusWin || bFocus);
|
||||
#else
|
||||
return true;
|
||||
#endif
|
||||
return g_PADInitialize->pRendererHasFocus();
|
||||
}
|
||||
|
||||
// copied from GCPad
|
||||
|
Reference in New Issue
Block a user