Commit e11ba0f5d9df9714464b78dca156fbfa862b468b

pionere 2022-01-08T12:03:57

do not load/unload opengl library when SDL_WINDOW_METAL flag is changed

diff --git a/src/video/SDL_video.c b/src/video/SDL_video.c
index e397783..1ab9835 100644
--- a/src/video/SDL_video.c
+++ b/src/video/SDL_video.c
@@ -1867,17 +1867,6 @@ SDL_RecreateWindow(SDL_Window * window, Uint32 flags)
         need_gl_load  = SDL_TRUE;
     }
 
-    if ((window->flags & SDL_WINDOW_METAL) != (flags & SDL_WINDOW_METAL)) {
-        if (flags & SDL_WINDOW_METAL) {
-            need_gl_load = SDL_TRUE;
-        } else {
-            need_gl_unload = SDL_TRUE;
-        }
-    } else if (window->flags & SDL_WINDOW_METAL) {
-        need_gl_unload = SDL_TRUE;
-        need_gl_load  = SDL_TRUE;
-    }
-
     if ((window->flags & SDL_WINDOW_VULKAN) != (flags & SDL_WINDOW_VULKAN)) {
         if (flags & SDL_WINDOW_VULKAN) {
             need_vulkan_load = SDL_TRUE;