mirror of
https://github.com/libretro/RetroArch
synced 2025-04-07 13:23:32 +00:00
Start restricting scope of g_x11_has_focus
This commit is contained in:
parent
91144ed53f
commit
d23557d38e
@ -304,6 +304,8 @@ unsigned x11_get_xinerama_monitor(Display *dpy, int x, int y,
|
|||||||
|
|
||||||
bool x11_create_input_context(Display *dpy, Window win, XIM *xim, XIC *xic)
|
bool x11_create_input_context(Display *dpy, Window win, XIM *xim, XIC *xic)
|
||||||
{
|
{
|
||||||
|
g_x11_has_focus = true;
|
||||||
|
|
||||||
*xim = XOpenIM(dpy, NULL, NULL, NULL);
|
*xim = XOpenIM(dpy, NULL, NULL, NULL);
|
||||||
|
|
||||||
if (!*xim)
|
if (!*xim)
|
||||||
|
@ -557,7 +557,6 @@ static void *xv_init(const video_info_t *video,
|
|||||||
x11_install_sighandlers();
|
x11_install_sighandlers();
|
||||||
|
|
||||||
xv_set_nonblock_state(xv, !video->vsync);
|
xv_set_nonblock_state(xv, !video->vsync);
|
||||||
g_x11_has_focus = true;
|
|
||||||
|
|
||||||
driver->display_type = RARCH_DISPLAY_X11;
|
driver->display_type = RARCH_DISPLAY_X11;
|
||||||
driver->video_display = (uintptr_t)g_x11_dpy;
|
driver->video_display = (uintptr_t)g_x11_dpy;
|
||||||
|
@ -535,7 +535,6 @@ static bool gfx_ctx_glx_set_video_mode(void *data,
|
|||||||
XSetErrorHandler(old_handler);
|
XSetErrorHandler(old_handler);
|
||||||
|
|
||||||
XFree(vi);
|
XFree(vi);
|
||||||
g_x11_has_focus = true;
|
|
||||||
|
|
||||||
if (!x11_create_input_context(g_x11_dpy, g_x11_win, &glx->g_xim, &g_x11_xic))
|
if (!x11_create_input_context(g_x11_dpy, g_x11_win, &glx->g_xim, &g_x11_xic))
|
||||||
goto error;
|
goto error;
|
||||||
|
@ -485,7 +485,6 @@ static bool gfx_ctx_xegl_set_video_mode(void *data,
|
|||||||
XSetErrorHandler(old_handler);
|
XSetErrorHandler(old_handler);
|
||||||
|
|
||||||
XFree(vi);
|
XFree(vi);
|
||||||
g_x11_has_focus = true;
|
|
||||||
g_inited = true;
|
g_inited = true;
|
||||||
|
|
||||||
if (!x11_create_input_context(g_x11_dpy, g_x11_win, &g_xim, &g_x11_xic))
|
if (!x11_create_input_context(g_x11_dpy, g_x11_win, &g_xim, &g_x11_xic))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user