Fixed bug 3745 - specify SDLCALL as the calling convention for API callbacks

Patches contributed by Ozkan Sezer
This commit is contained in:
Sam Lantinga
2017-08-14 06:28:21 -07:00
parent d03409e118
commit de91b1248f
23 changed files with 40 additions and 38 deletions

View File

@@ -445,7 +445,7 @@ RLEClipBlit(int w, Uint8 * srcbuf, SDL_Surface * surf_dst,
/* blit a colorkeyed RLE surface */
int
int SDLCALL
SDL_RLEBlit(SDL_Surface * surf_src, SDL_Rect * srcrect,
SDL_Surface * surf_dst, SDL_Rect * dstrect)
{
@@ -723,7 +723,7 @@ RLEAlphaClipBlit(int w, Uint8 * srcbuf, SDL_Surface * surf_dst,
}
/* blit a pixel-alpha RLE surface */
int
int SDLCALL
SDL_RLEAlphaBlit(SDL_Surface * surf_src, SDL_Rect * srcrect,
SDL_Surface * surf_dst, SDL_Rect * dstrect)
{

View File

@@ -23,9 +23,9 @@
/* Useful functions and variables from SDL_RLEaccel.c */
extern int SDL_RLESurface(SDL_Surface * surface);
extern int SDL_RLEBlit(SDL_Surface * src, SDL_Rect * srcrect,
SDL_Surface * dst, SDL_Rect * dstrect);
extern int SDL_RLEAlphaBlit(SDL_Surface * src, SDL_Rect * srcrect,
SDL_Surface * dst, SDL_Rect * dstrect);
extern int SDLCALL SDL_RLEBlit (SDL_Surface * src, SDL_Rect * srcrect,
SDL_Surface * dst, SDL_Rect * dstrect);
extern int SDLCALL SDL_RLEAlphaBlit(SDL_Surface * src, SDL_Rect * srcrect,
SDL_Surface * dst, SDL_Rect * dstrect);
extern void SDL_UnRLESurface(SDL_Surface * surface, int recode);
/* vi: set ts=4 sw=4 expandtab: */

View File

@@ -30,7 +30,7 @@
#include "SDL_pixels_c.h"
/* The general purpose software blit routine */
static int
static int SDLCALL
SDL_SoftBlit(SDL_Surface * src, SDL_Rect * srcrect,
SDL_Surface * dst, SDL_Rect * dstrect)
{

View File

@@ -52,7 +52,7 @@ static void Android_GetWindowCoordinates(float x, float y,
static SDL_bool separate_mouse_and_touch = SDL_FALSE;
static void
static void SDLCALL
SeparateEventsHintWatcher(void *userdata, const char *name,
const char *oldValue, const char *newValue)
{

View File

@@ -69,7 +69,7 @@ int main(int argc, char **argv)
return exit_status;
}
static void
static void SDLCALL
SDL_IdleTimerDisabledChanged(void *userdata, const char *name, const char *oldValue, const char *hint)
{
BOOL disable = (hint && *hint != '0');

View File

@@ -40,7 +40,7 @@
#endif
#if TARGET_OS_TV
static void
static void SDLCALL
SDL_AppleTVControllerUIHintChanged(void *userdata, const char *name, const char *oldValue, const char *hint)
{
@autoreleasepool {

View File

@@ -178,7 +178,8 @@ void Wayland_ShowWindow(_THIS, SDL_Window *window)
}
#ifdef SDL_VIDEO_DRIVER_WAYLAND_QT_TOUCH
static void QtExtendedSurface_OnHintChanged(void *userdata, const char *name,
static void SDLCALL
QtExtendedSurface_OnHintChanged(void *userdata, const char *name,
const char *oldValue, const char *newValue)
{
struct qt_extended_surface *qt_extended_surface = userdata;

View File

@@ -42,7 +42,8 @@ static void WIN_VideoQuit(_THIS);
SDL_bool g_WindowsEnableMessageLoop = SDL_TRUE;
SDL_bool g_WindowFrameUsableWhileCursorHidden = SDL_TRUE;
static void UpdateWindowsEnableMessageLoop(void *userdata, const char *name, const char *oldValue, const char *newValue)
static void SDLCALL
UpdateWindowsEnableMessageLoop(void *userdata, const char *name, const char *oldValue, const char *newValue)
{
if (newValue && *newValue == '0') {
g_WindowsEnableMessageLoop = SDL_FALSE;
@@ -51,7 +52,8 @@ static void UpdateWindowsEnableMessageLoop(void *userdata, const char *name, con
}
}
static void UpdateWindowFrameUsableWhileCursorHidden(void *userdata, const char *name, const char *oldValue, const char *newValue)
static void SDLCALL
UpdateWindowFrameUsableWhileCursorHidden(void *userdata, const char *name, const char *oldValue, const char *newValue)
{
if (newValue && *newValue == '0') {
g_WindowFrameUsableWhileCursorHidden = SDL_FALSE;