From 7b9126180325496cc0f2179ca2d166eb5eaae3b6 Mon Sep 17 00:00:00 2001
From: Ozkan Sezer <[EMAIL REDACTED]>
Date: Wed, 17 Nov 2021 10:56:48 +0300
Subject: [PATCH] fixed windows build against latest SDL2 headers and added a
FIXME note.
---
src/SDL12_compat.c | 1 +
src/SDL20_include_wrapper.h | 4 ++++
2 files changed, 5 insertions(+)
diff --git a/src/SDL12_compat.c b/src/SDL12_compat.c
index a550b29..a1dc664 100644
--- a/src/SDL12_compat.c
+++ b/src/SDL12_compat.c
@@ -1259,6 +1259,7 @@ SDL_SetModuleHandle(void *handle)
(void) handle;/* handled internally by SDL2 - nothing to do.. */
}
+/* FIXME: forward these two to the SDL2 versions ? */
DECLSPEC int SDLCALL
SDL_RegisterApp(char *name, Uint32 style, void *hInst)
{
diff --git a/src/SDL20_include_wrapper.h b/src/SDL20_include_wrapper.h
index cfd1d84..57d7ca5 100644
--- a/src/SDL20_include_wrapper.h
+++ b/src/SDL20_include_wrapper.h
@@ -98,6 +98,8 @@
#define SDL_VideoInit IGNORE_THIS_VERSION_OF_SDL_VideoInit
#define SDL_BuildAudioCVT IGNORE_THIS_VERSION_OF_SDL_BuildAudioCVT
#define SDL_ConvertAudio IGNORE_THIS_VERSION_OF_SDL_ConvertAudio
+#define SDL_RegisterApp IGNORE_THIS_VERSION_OF_SDL_RegisterApp
+#define SDL_UnregisterApp IGNORE_THIS_VERSION_OF_SDL_UnregisterApp
#define BUILD_SDL 1
@@ -211,6 +213,8 @@ typedef void (__cdecl *pfnSDL_CurrentEndThread) (unsigned);
#undef SDL_VideoInit
#undef SDL_BuildAudioCVT
#undef SDL_ConvertAudio
+#undef SDL_RegisterApp
+#undef SDL_UnregisterApp
#ifdef SDL_mutexP
#undef SDL_mutexP