diff options
| author | Bryce Harrington <b.harrington@samsung.com> | 2013-12-18 15:39:37 -0800 |
|---|---|---|
| committer | Bryce Harrington <b.harrington@samsung.com> | 2013-12-18 15:39:37 -0800 |
| commit | 599030c8fe3b60e9b23d6dab5e62122c8331ef6f (patch) | |
| tree | 855f90b650aa636ccc0473d808276638f8ce25f3 /src/egl.cpp | |
| parent | efdd7f7835e281cea9d6955696593361b5067c21 (diff) | |
Make destructors called explicitly rather than through callbacks
While Cairo has callback support for the destructor, there's not an
analogous way to do this with Skia, so instead of trying to be clever
let's just build explicit destruction in.
Diffstat (limited to 'src/egl.cpp')
| -rw-r--r-- | src/egl.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/egl.cpp b/src/egl.cpp index 82ba9cd..992d431 100644 --- a/src/egl.cpp +++ b/src/egl.cpp @@ -93,3 +93,11 @@ destroyEGLContextAndWindow (egl_state_t *state) XCloseDisplay (state->dpy); } } + +void +cleanup_state_egl(void *data) +{ + egl_state_t *state = (egl_state_t*)data; + destroyEGLContextAndWindow(state); + free(state); +} |