cairo-texture: Skip ::draw emission for 0x0 surfaces
This also avoids an assertion failure.
This commit is contained in:
parent
225820c4b4
commit
90f37d5636
@ -330,6 +330,12 @@ clutter_cairo_texture_emit_draw (ClutterCairoTexture *self,
|
||||
gboolean result;
|
||||
cairo_t *cr;
|
||||
|
||||
/* 0x0 surfaces don't need a ::draw */
|
||||
if (self->priv->surface_width == 0 ||
|
||||
self->priv->surface_height == 0)
|
||||
return;
|
||||
|
||||
/* if the size is !0 then we must have a surface */
|
||||
g_assert (self->priv->cr_surface != NULL);
|
||||
|
||||
cr = cairo_create (self->priv->cr_surface);
|
||||
|
Loading…
Reference in New Issue
Block a user