From 0df3f13fc9f1df425c69495815c99d7a105acb67 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Thu, 9 Apr 2015 22:38:11 +0200 Subject: [PATCH] Revert "Create wrapper gfx_ctx_check_window" This reverts commit 4d3b1872313894101bf05cd69215ecc55ebe8bb2. --- gfx/drivers/gl.c | 9 +++++++-- gfx/video_context_driver.c | 16 ---------------- gfx/video_context_driver.h | 3 --- 3 files changed, 7 insertions(+), 21 deletions(-) diff --git a/gfx/drivers/gl.c b/gfx/drivers/gl.c index b9aadc574f..22a45d7a39 100644 --- a/gfx/drivers/gl.c +++ b/gfx/drivers/gl.c @@ -2469,11 +2469,16 @@ static bool gl_alive(void *data) { bool quit = false, resize = false; gl_t *gl = (gl_t*)data; + runloop_t *runloop = rarch_main_get_ptr(); + const gfx_ctx_driver_t *ctx = gfx_ctx_get_ptr(); - if (gfx_ctx_check_window(gl, &quit, - &resize, &gl->win_width, &gl->win_height)) + if (!gl) return false; + ctx->check_window(gl, &quit, + &resize, &gl->win_width, &gl->win_height, + runloop->frames.video.count); + if (quit) gl->quitting = true; else if (resize) diff --git a/gfx/video_context_driver.c b/gfx/video_context_driver.c index 12697f8c61..1edb176986 100644 --- a/gfx/video_context_driver.c +++ b/gfx/video_context_driver.c @@ -82,22 +82,6 @@ const gfx_ctx_driver_t *gfx_ctx_get_ptr(void) return (const gfx_ctx_driver_t*)driver->video_context; } -bool gfx_ctx_check_window(void *data, bool *quit, - bool *resize, unsigned *width, unsigned *height) -{ - const gfx_ctx_driver_t *ctx = gfx_ctx_get_ptr(); - runloop_t *runloop = rarch_main_get_ptr(); - - if (!data) - return false; - - ctx->check_window(data, quit, resize, - width, height, - runloop->frames.video.count); - - return true; -} - void gfx_ctx_swap_buffers(void *data) { const gfx_ctx_driver_t *ctx = gfx_ctx_get_ptr(); diff --git a/gfx/video_context_driver.h b/gfx/video_context_driver.h index 843a1a34b8..122e967a96 100644 --- a/gfx/video_context_driver.h +++ b/gfx/video_context_driver.h @@ -215,9 +215,6 @@ void gfx_ctx_swap_buffers(void *data); bool gfx_ctx_focus(void *data); -bool gfx_ctx_check_window(void *data, bool *quit, - bool *resize, unsigned *width, unsigned *height); - #ifdef __cplusplus } #endif