mirror of
https://github.com/brl/mutter.git
synced 2025-01-11 04:02:36 +00:00
gdk: Use X11 API only when running under X11
Avoid using GdkX11Screen API when the GDK backend being used is not the X11 one. https://bugzilla.gnome.org/show_bug.cgi?id=752143
This commit is contained in:
parent
41cd804f10
commit
365bd482fb
@ -534,11 +534,12 @@ clutter_gdk_get_visual (void)
|
|||||||
g_assert (screen != NULL);
|
g_assert (screen != NULL);
|
||||||
|
|
||||||
#if defined(GDK_WINDOWING_X11) && defined(COGL_HAS_XLIB_SUPPORT)
|
#if defined(GDK_WINDOWING_X11) && defined(COGL_HAS_XLIB_SUPPORT)
|
||||||
{
|
if (GDK_IS_X11_SCREEN (screen))
|
||||||
XVisualInfo *xvisinfo = cogl_clutter_winsys_xlib_get_visual_info ();
|
{
|
||||||
if (xvisinfo != NULL)
|
XVisualInfo *xvisinfo = cogl_clutter_winsys_xlib_get_visual_info ();
|
||||||
return gdk_x11_screen_lookup_visual (screen, xvisinfo->visualid);
|
if (xvisinfo != NULL)
|
||||||
}
|
return gdk_x11_screen_lookup_visual (screen, xvisinfo->visualid);
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (gdk_screen_get_rgba_visual (screen) != NULL)
|
if (gdk_screen_get_rgba_visual (screen) != NULL)
|
||||||
|
Loading…
Reference in New Issue
Block a user