summaryrefslogtreecommitdiff
path: root/src/lib/ecore_wl2/ecore_wl2_surface.c
diff options
context:
space:
mode:
authorDerek Foreman <derekf@osg.samsung.com>2018-01-25 14:37:16 -0600
committerDerek Foreman <derekf@osg.samsung.com>2018-01-26 15:53:59 -0600
commit84f703cf675315f5ef90f3ffc46db2cc3234fce6 (patch)
treebf899ecae3c5402086ce5f64073c027c930de224 /src/lib/ecore_wl2/ecore_wl2_surface.c
parentbf4b828cb6537c5e0cb9287669877f6ff2344fb6 (diff)
ecore_wl2: Call check function through a pointer
We'll need this in the function array when we make surface managers modular.
Diffstat (limited to 'src/lib/ecore_wl2/ecore_wl2_surface.c')
-rw-r--r--src/lib/ecore_wl2/ecore_wl2_surface.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/lib/ecore_wl2/ecore_wl2_surface.c b/src/lib/ecore_wl2/ecore_wl2_surface.c
index de10b8ad5f..9ee1df9695 100644
--- a/src/lib/ecore_wl2/ecore_wl2_surface.c
+++ b/src/lib/ecore_wl2/ecore_wl2_surface.c
@@ -245,18 +245,20 @@ ecore_wl2_surface_create(Ecore_Wl2_Window *win, Eina_Bool alpha)
245 out->w = 0; 245 out->w = 0;
246 out->h = 0; 246 out->h = 0;
247 247
248 if (!_evas_dmabuf_surface_check(win)) goto err; 248 out->funcs.check = _evas_dmabuf_surface_check;
249
250 out->funcs.destroy = _evas_dmabuf_surface_destroy; 249 out->funcs.destroy = _evas_dmabuf_surface_destroy;
251 out->funcs.reconfigure = _evas_dmabuf_surface_reconfigure; 250 out->funcs.reconfigure = _evas_dmabuf_surface_reconfigure;
252 out->funcs.data_get = _evas_dmabuf_surface_data_get; 251 out->funcs.data_get = _evas_dmabuf_surface_data_get;
253 out->funcs.assign = _evas_dmabuf_surface_assign; 252 out->funcs.assign = _evas_dmabuf_surface_assign;
254 out->funcs.post = _evas_dmabuf_surface_post; 253 out->funcs.post = _evas_dmabuf_surface_post;
255 out->funcs.flush = _surface_flush; 254 out->funcs.flush = _surface_flush;
256 win->wl2_surface = out;
257 return out;
258 255
259err: 256 if (out->funcs.check(win))
257 {
258 win->wl2_surface = out;
259 return out;
260 }
261
260 free(out); 262 free(out);
261 return NULL; 263 return NULL;
262} 264}