egl: Don't try to use stage_x11 with non-X winsys

The access to stage_x11 has to be protected by COGL_HAS_X11_SUPPORT.
This commit is contained in:
Damien Lespiau 2010-11-30 10:06:12 -05:00
parent 4ceb95d2ca
commit 9ad55edf24

View File

@ -455,11 +455,14 @@ _clutter_stage_egl_redraw (ClutterStageEGL *stage_egl,
stage_egl->bounding_redraw_clip.width != 0 && stage_egl->bounding_redraw_clip.width != 0 &&
/* some drivers struggle to get going and produce some junk /* some drivers struggle to get going and produce some junk
* frames when starting up... */ * frames when starting up... */
G_LIKELY (stage_egl->frame_count > 3) && G_LIKELY (stage_egl->frame_count > 3)
#ifdef COGL_HAS_X11_SUPPORT
/* While resizing a window clipped redraws are disabled to avoid /* While resizing a window clipped redraws are disabled to avoid
* artefacts. See clutter-event-x11.c:event_translate for a * artefacts. See clutter-event-x11.c:event_translate for a
* detailed explanation */ * detailed explanation */
G_LIKELY (stage_x11->clipped_redraws_cool_off == 0)) && G_LIKELY (stage_x11->clipped_redraws_cool_off == 0)
#endif
)
may_use_clipped_redraw = TRUE; may_use_clipped_redraw = TRUE;
else else
may_use_clipped_redraw = FALSE; may_use_clipped_redraw = FALSE;