From: Alex Wu <zhiwen.wu@linux.intel.com>

Date: Sat, 5 Jan 2013 10:50:19 +0800
Subject: [PATCH] ecore-wayland: Improve opaque setting logic.

1. Update win->region.opaque in ecore_wl_window_update_size, so that
the opaque info is synced with the geometry.

2. Add win->surface checking in ecore_wl_window_buffer_attach
before send any wl_surface related request, it will avoid segfault
in case that calling ecore_wl_window_buffer_attach() before
ecore_wl_window_show().

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 82385
This commit is contained in:
Alex Wu 2013-01-08 07:21:47 +00:00 committed by Christopher Michael
parent 67769cc39f
commit 41308aa729
1 changed files with 2 additions and 3 deletions

View File

@ -241,8 +241,7 @@ ecore_wl_window_buffer_attach(Ecore_Wl_Window *win, struct wl_buffer *buffer, in
return;
}
if (!win->surface)
return;
if (!win->surface) return;
if (win->region.input)
{
@ -425,7 +424,7 @@ ecore_wl_window_update_size(Ecore_Wl_Window *win, int w, int h)
win->allocation.w = w;
win->allocation.h = h;
if (!win->transparent || !win->alpha)
if ((!win->transparent) || (!win->alpha))
{
if (win->region.opaque) wl_region_destroy(win->region.opaque);
win->region.opaque =