comparison nuklear_ui/blastem_nuklear.c @ 1681:3f1c8258e20f

Hopefully fix Nuklear assert when loading ROM after changing video settings that some users are reporting
author Michael Pavone <pavone@retrodev.com>
date Thu, 17 Jan 2019 19:13:59 -0800
parents 357b4951d9b2
children ba3fb7a3be6b
comparison
equal deleted inserted replaced
1680:326d1a601fb9 1681:3f1c8258e20f
1870 nk_sdl_handle_event(event); 1870 nk_sdl_handle_event(event);
1871 } 1871 }
1872 1872
1873 static void context_destroyed(void) 1873 static void context_destroyed(void)
1874 { 1874 {
1875 nk_sdl_shutdown(); 1875 if (context)
1876 {
1877 nk_sdl_shutdown();
1878 context = NULL;
1879 }
1876 } 1880 }
1877 1881
1878 static struct nk_image load_image_texture(uint32_t *buf, uint32_t width, uint32_t height) 1882 static struct nk_image load_image_texture(uint32_t *buf, uint32_t width, uint32_t height)
1879 { 1883 {
1880 GLuint tex; 1884 GLuint tex;