forked from enlightenment/enlightenment
E Comp (wayland): Handle destroy & create of egl images for surface.
SVN revision: 67466
This commit is contained in:
parent
50dd8bd43f
commit
6d650eb556
|
@ -38,6 +38,7 @@ e_mod_comp_wl_surface_create(int32_t x, int32_t y, int32_t width, int32_t height
|
||||||
surface->surface.resource.client = NULL;
|
surface->surface.resource.client = NULL;
|
||||||
|
|
||||||
surface->visual = WAYLAND_NONE_VISUAL;
|
surface->visual = WAYLAND_NONE_VISUAL;
|
||||||
|
surface->image = EGL_NO_IMAGE_KHR;
|
||||||
surface->saved_texture = 0;
|
surface->saved_texture = 0;
|
||||||
surface->x = x;
|
surface->x = x;
|
||||||
surface->y = y;
|
surface->y = y;
|
||||||
|
@ -163,6 +164,14 @@ e_mod_comp_wl_surface_destroy_surface(struct wl_resource *resource)
|
||||||
if (ws->buffer)
|
if (ws->buffer)
|
||||||
wl_list_remove(&ws->buffer_destroy_listener.link);
|
wl_list_remove(&ws->buffer_destroy_listener.link);
|
||||||
|
|
||||||
|
if (ws->image != EGL_NO_IMAGE_KHR)
|
||||||
|
{
|
||||||
|
Wayland_Compositor *comp;
|
||||||
|
|
||||||
|
comp = e_mod_comp_wl_comp_get();
|
||||||
|
comp->destroy_image(comp->egl.display, ws->image);
|
||||||
|
}
|
||||||
|
|
||||||
wl_list_remove(&ws->buffer_link);
|
wl_list_remove(&ws->buffer_link);
|
||||||
|
|
||||||
pixman_region32_fini(&ws->damage);
|
pixman_region32_fini(&ws->damage);
|
||||||
|
|
Loading…
Reference in New Issue