comparison vdp.c @ 2030:bcc85f6b06c2

Close VDP debug windows when VDP is freed. Fixes Trac bug 39
author Michael Pavone <pavone@retrodev.com>
date Sat, 20 Feb 2021 12:47:26 -0800
parents dcdad92f84a4
children 441d5d6cea2f
comparison
equal deleted inserted replaced
2029:1e7a63f0ccf4 2030:bcc85f6b06c2
252 return context; 252 return context;
253 } 253 }
254 254
255 void vdp_free(vdp_context *context) 255 void vdp_free(vdp_context *context)
256 { 256 {
257 if (headless) {
258 free(context->fb);
259 }
260 for (int i = 0; i < VDP_NUM_DEBUG_TYPES; i++)
261 {
262 if (context->enabled_debuggers & (1 << i)) {
263 vdp_toggle_debug_view(context, i);
264 }
265 }
257 free(context); 266 free(context);
258 } 267 }
259 268
260 static int is_refresh(vdp_context * context, uint32_t slot) 269 static int is_refresh(vdp_context * context, uint32_t slot)
261 { 270 {