From 23beef4fc7e0d218e02ebbcd363adae63254c54d Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Thu, 12 Jan 2023 15:55:52 -0800 Subject: [PATCH] We no longer need explicit SDL_ENABLE_SYSWM_* while building SDL --- src/core/linux/SDL_fcitx.c | 1 - src/core/linux/SDL_ibus.c | 1 - src/render/direct3d/SDL_render_d3d.c | 1 - src/render/direct3d11/SDL_render_d3d11.c | 1 - src/render/direct3d11/SDL_render_winrt.cpp | 1 - src/render/direct3d12/SDL_render_d3d12.c | 1 - src/render/metal/SDL_render_metal.m | 2 -- src/video/android/SDL_androidvulkan.c | 1 - src/video/android/SDL_androidwindow.c | 1 - src/video/cocoa/SDL_cocoametalview.m | 1 - src/video/cocoa/SDL_cocoavulkan.m | 1 - src/video/cocoa/SDL_cocoawindow.m | 1 - src/video/kmsdrm/SDL_kmsdrmvideo.c | 1 - src/video/kmsdrm/SDL_kmsdrmvulkan.c | 1 - src/video/uikit/SDL_uikitmetalview.m | 1 - src/video/uikit/SDL_uikitvulkan.m | 1 - src/video/uikit/SDL_uikitwindow.m | 1 - src/video/wayland/SDL_waylandvulkan.c | 1 - src/video/wayland/SDL_waylandwindow.h | 1 - src/video/windows/SDL_windowsevents.c | 1 - src/video/windows/SDL_windowsvulkan.c | 1 - src/video/windows/SDL_windowswindow.c | 1 - src/video/winrt/SDL_winrtvideo.cpp | 1 - src/video/x11/SDL_x11events.c | 1 - src/video/x11/SDL_x11window.c | 1 - 25 files changed, 26 deletions(-) diff --git a/src/core/linux/SDL_fcitx.c b/src/core/linux/SDL_fcitx.c index 7d4aa52ab..103d55cc5 100644 --- a/src/core/linux/SDL_fcitx.c +++ b/src/core/linux/SDL_fcitx.c @@ -28,7 +28,6 @@ #ifdef SDL_VIDEO_DRIVER_X11 #include "../../video/x11/SDL_x11video.h" -#define SDL_ENABLE_SYSWM_X11 #endif #include diff --git a/src/core/linux/SDL_ibus.c b/src/core/linux/SDL_ibus.c index 3f41d396e..a95547005 100644 --- a/src/core/linux/SDL_ibus.c +++ b/src/core/linux/SDL_ibus.c @@ -28,7 +28,6 @@ #ifdef SDL_VIDEO_DRIVER_X11 #include "../../video/x11/SDL_x11video.h" -#define SDL_ENABLE_SYSWM_X11 #endif #include diff --git a/src/render/direct3d/SDL_render_d3d.c b/src/render/direct3d/SDL_render_d3d.c index dbfb1e535..c8db69c6c 100644 --- a/src/render/direct3d/SDL_render_d3d.c +++ b/src/render/direct3d/SDL_render_d3d.c @@ -28,7 +28,6 @@ #include "../SDL_d3dmath.h" #include "../../video/windows/SDL_windowsvideo.h" -#define SDL_ENABLE_SYSWM_WINDOWS #include #if SDL_VIDEO_RENDER_D3D diff --git a/src/render/direct3d11/SDL_render_d3d11.c b/src/render/direct3d11/SDL_render_d3d11.c index 470af7156..1023cfcd6 100644 --- a/src/render/direct3d11/SDL_render_d3d11.c +++ b/src/render/direct3d11/SDL_render_d3d11.c @@ -30,7 +30,6 @@ #include "../SDL_sysrender.h" #include "../SDL_d3dmath.h" -#define SDL_ENABLE_SYSWM_WINDOWS #include #include diff --git a/src/render/direct3d11/SDL_render_winrt.cpp b/src/render/direct3d11/SDL_render_winrt.cpp index 7b9a0fb3c..4d38c471c 100644 --- a/src/render/direct3d11/SDL_render_winrt.cpp +++ b/src/render/direct3d11/SDL_render_winrt.cpp @@ -39,7 +39,6 @@ using namespace Windows::Graphics::Display; #include -#define SDL_ENABLE_SYSWM_WINRT #include #include "SDL_render_winrt.h" diff --git a/src/render/direct3d12/SDL_render_d3d12.c b/src/render/direct3d12/SDL_render_d3d12.c index c72d8c212..574a1c5ad 100644 --- a/src/render/direct3d12/SDL_render_d3d12.c +++ b/src/render/direct3d12/SDL_render_d3d12.c @@ -32,7 +32,6 @@ #include "../SDL_sysrender.h" #include "../SDL_d3dmath.h" -#define SDL_ENABLE_SYSWM_WINDOWS #include #if defined(__XBOXONE__) || defined(__XBOXSERIES__) diff --git a/src/render/metal/SDL_render_metal.m b/src/render/metal/SDL_render_metal.m index bce28f18c..d3f594fea 100644 --- a/src/render/metal/SDL_render_metal.m +++ b/src/render/metal/SDL_render_metal.m @@ -31,11 +31,9 @@ #ifdef SDL_VIDEO_DRIVER_COCOA #import #import -#define SDL_ENABLE_SYSWM_COCOA #endif #ifdef SDL_VIDEO_DRIVER_UIKIT #import -#define SDL_ENABLE_SYSWM_UIKIT #endif #include diff --git a/src/video/android/SDL_androidvulkan.c b/src/video/android/SDL_androidvulkan.c index a848d823b..37ba6a41f 100644 --- a/src/video/android/SDL_androidvulkan.c +++ b/src/video/android/SDL_androidvulkan.c @@ -33,7 +33,6 @@ #include "SDL_androidvulkan.h" -#define SDL_ENABLE_SYSWM_ANDROID #include int Android_Vulkan_LoadLibrary(_THIS, const char *path) diff --git a/src/video/android/SDL_androidwindow.c b/src/video/android/SDL_androidwindow.c index 76d19eba7..598b774d5 100644 --- a/src/video/android/SDL_androidwindow.c +++ b/src/video/android/SDL_androidwindow.c @@ -31,7 +31,6 @@ #include "SDL_androidvideo.h" #include "SDL_androidwindow.h" -#define SDL_ENABLE_SYSWM_ANDROID #include /* Currently only one window */ diff --git a/src/video/cocoa/SDL_cocoametalview.m b/src/video/cocoa/SDL_cocoametalview.m index a5caea5a2..b5a4fa1cb 100644 --- a/src/video/cocoa/SDL_cocoametalview.m +++ b/src/video/cocoa/SDL_cocoametalview.m @@ -30,7 +30,6 @@ #if SDL_VIDEO_DRIVER_COCOA && (SDL_VIDEO_VULKAN || SDL_VIDEO_METAL) -#define SDL_ENABLE_SYSWM_COCOA #include static int SDLCALL SDL_MetalViewEventWatch(void *userdata, SDL_Event *event) diff --git a/src/video/cocoa/SDL_cocoavulkan.m b/src/video/cocoa/SDL_cocoavulkan.m index 53d61fbb7..e0905315e 100644 --- a/src/video/cocoa/SDL_cocoavulkan.m +++ b/src/video/cocoa/SDL_cocoavulkan.m @@ -33,7 +33,6 @@ #include "SDL_cocoametalview.h" #include "SDL_cocoavulkan.h" -#define SDL_ENABLE_SYSWM_COCOA #include #include diff --git a/src/video/cocoa/SDL_cocoawindow.m b/src/video/cocoa/SDL_cocoawindow.m index b59390c42..94f53190e 100644 --- a/src/video/cocoa/SDL_cocoawindow.m +++ b/src/video/cocoa/SDL_cocoawindow.m @@ -41,7 +41,6 @@ #include "SDL_cocoaopengl.h" #include "SDL_cocoaopengles.h" -#define SDL_ENABLE_SYSWM_COCOA #include /* #define DEBUG_COCOAWINDOW */ diff --git a/src/video/kmsdrm/SDL_kmsdrmvideo.c b/src/video/kmsdrm/SDL_kmsdrmvideo.c index eea262397..93b4ca46c 100644 --- a/src/video/kmsdrm/SDL_kmsdrmvideo.c +++ b/src/video/kmsdrm/SDL_kmsdrmvideo.c @@ -35,7 +35,6 @@ #include "../../core/openbsd/SDL_wscons.h" #endif -#define SDL_ENABLE_SYSWM_KMSDRM #include /* KMS/DRM declarations */ diff --git a/src/video/kmsdrm/SDL_kmsdrmvulkan.c b/src/video/kmsdrm/SDL_kmsdrmvulkan.c index eda858d66..fcdf10892 100644 --- a/src/video/kmsdrm/SDL_kmsdrmvulkan.c +++ b/src/video/kmsdrm/SDL_kmsdrmvulkan.c @@ -32,7 +32,6 @@ #include "SDL_kmsdrmdyn.h" #include "SDL_kmsdrmvulkan.h" -#define SDL_ENABLE_SYSWM_KMSDRM #include #include diff --git a/src/video/uikit/SDL_uikitmetalview.m b/src/video/uikit/SDL_uikitmetalview.m index 066057e0c..cdb3b80e1 100644 --- a/src/video/uikit/SDL_uikitmetalview.m +++ b/src/video/uikit/SDL_uikitmetalview.m @@ -35,7 +35,6 @@ #import "SDL_uikitwindow.h" #import "SDL_uikitmetalview.h" -#define SDL_ENABLE_SYSWM_UIKIT #include @implementation SDL_uikitmetalview diff --git a/src/video/uikit/SDL_uikitvulkan.m b/src/video/uikit/SDL_uikitvulkan.m index 09bf4948c..4c0578f3e 100644 --- a/src/video/uikit/SDL_uikitvulkan.m +++ b/src/video/uikit/SDL_uikitvulkan.m @@ -34,7 +34,6 @@ #include "SDL_uikitvulkan.h" #include "SDL_uikitmetalview.h" -#define SDL_ENABLE_SYSWM_UIKIT #include #include diff --git a/src/video/uikit/SDL_uikitwindow.m b/src/video/uikit/SDL_uikitwindow.m index 543904f93..eb0abe1a8 100644 --- a/src/video/uikit/SDL_uikitwindow.m +++ b/src/video/uikit/SDL_uikitwindow.m @@ -34,7 +34,6 @@ #include "SDL_uikitview.h" #include "SDL_uikitopenglview.h" -#define SDL_ENABLE_SYSWM_UIKIT #include #include diff --git a/src/video/wayland/SDL_waylandvulkan.c b/src/video/wayland/SDL_waylandvulkan.c index 0439b8797..c498ee46d 100644 --- a/src/video/wayland/SDL_waylandvulkan.c +++ b/src/video/wayland/SDL_waylandvulkan.c @@ -33,7 +33,6 @@ #include "SDL_waylandvulkan.h" -#define SDL_ENABLE_SYSWM_WAYLAND #include #if defined(__OpenBSD__) diff --git a/src/video/wayland/SDL_waylandwindow.h b/src/video/wayland/SDL_waylandwindow.h index f672df29e..e8130280f 100644 --- a/src/video/wayland/SDL_waylandwindow.h +++ b/src/video/wayland/SDL_waylandwindow.h @@ -27,7 +27,6 @@ #include "../SDL_sysvideo.h" #include "../../events/SDL_touch_c.h" -#define SDL_ENABLE_SYSWM_WAYLAND #include #include "SDL_waylandvideo.h" diff --git a/src/video/windows/SDL_windowsevents.c b/src/video/windows/SDL_windowsevents.c index 20337e90d..e3d115337 100644 --- a/src/video/windows/SDL_windowsevents.c +++ b/src/video/windows/SDL_windowsevents.c @@ -29,7 +29,6 @@ #include "../../events/SDL_touch_c.h" #include "../../events/scancodes_windows.h" -#define SDL_ENABLE_SYSWM_WINDOWS #include /* Dropfile support */ diff --git a/src/video/windows/SDL_windowsvulkan.c b/src/video/windows/SDL_windowsvulkan.c index 7190484ff..5fa3d367e 100644 --- a/src/video/windows/SDL_windowsvulkan.c +++ b/src/video/windows/SDL_windowsvulkan.c @@ -33,7 +33,6 @@ #include "SDL_windowsvulkan.h" -#define SDL_ENABLE_SYSWM_WINDOWS #include int WIN_Vulkan_LoadLibrary(_THIS, const char *path) diff --git a/src/video/windows/SDL_windowswindow.c b/src/video/windows/SDL_windowswindow.c index 31e672144..7f792dc82 100644 --- a/src/video/windows/SDL_windowswindow.c +++ b/src/video/windows/SDL_windowswindow.c @@ -38,7 +38,6 @@ /* Dropfile support */ #include -#define SDL_ENABLE_SYSWM_WINDOWS #include /* Windows CE compatibility */ diff --git a/src/video/winrt/SDL_winrtvideo.cpp b/src/video/winrt/SDL_winrtvideo.cpp index 8b160fb7b..fbb12a741 100644 --- a/src/video/winrt/SDL_winrtvideo.cpp +++ b/src/video/winrt/SDL_winrtvideo.cpp @@ -67,7 +67,6 @@ extern "C" { #include "SDL_winrtmouse_c.h" #include "SDL_winrtvideo_cpp.h" -#define SDL_ENABLE_SYSWM_WINRT #include /* Initialization/Query functions */ diff --git a/src/video/x11/SDL_x11events.c b/src/video/x11/SDL_x11events.c index 5f5609f1f..294b06887 100644 --- a/src/video/x11/SDL_x11events.c +++ b/src/video/x11/SDL_x11events.c @@ -37,7 +37,6 @@ #include "../../events/SDL_mouse_c.h" #include "../../events/SDL_touch_c.h" -#define SDL_ENABLE_SYSWM_X11 #include #include diff --git a/src/video/x11/SDL_x11window.c b/src/video/x11/SDL_x11window.c index e4d23c6cc..c088d21a6 100644 --- a/src/video/x11/SDL_x11window.c +++ b/src/video/x11/SDL_x11window.c @@ -38,7 +38,6 @@ #include "SDL_x11opengles.h" #endif -#define SDL_ENABLE_SYSWM_X11 #include #define _NET_WM_STATE_REMOVE 0l