mark SDL_ClipboardTextCallback as SDLCALL
This commit is contained in:
parent
168322f358
commit
ee5289ef09
2 changed files with 3 additions and 4 deletions
|
@ -253,7 +253,7 @@ static const char **SDL_GetTextMimeTypes(SDL_VideoDevice *_this, size_t *num_mim
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const void *SDL_ClipboardTextCallback(void *userdata, const char *mime_type, size_t *size)
|
const void * SDLCALL SDL_ClipboardTextCallback(void *userdata, const char *mime_type, size_t *size)
|
||||||
{
|
{
|
||||||
char *text = (char *)userdata;
|
char *text = (char *)userdata;
|
||||||
if (text) {
|
if (text) {
|
||||||
|
@ -278,9 +278,8 @@ int SDL_SetClipboardText(const char *text)
|
||||||
text_mime_types = SDL_GetTextMimeTypes(_this, &num_mime_types);
|
text_mime_types = SDL_GetTextMimeTypes(_this, &num_mime_types);
|
||||||
|
|
||||||
return SDL_SetClipboardData(SDL_ClipboardTextCallback, SDL_free, SDL_strdup(text), text_mime_types, num_mime_types);
|
return SDL_SetClipboardData(SDL_ClipboardTextCallback, SDL_free, SDL_strdup(text), text_mime_types, num_mime_types);
|
||||||
} else {
|
|
||||||
return SDL_ClearClipboardData();
|
|
||||||
}
|
}
|
||||||
|
return SDL_ClearClipboardData();
|
||||||
}
|
}
|
||||||
|
|
||||||
char *SDL_GetClipboardText(void)
|
char *SDL_GetClipboardText(void)
|
||||||
|
|
|
@ -37,6 +37,6 @@ extern void *SDL_GetInternalClipboardData(SDL_VideoDevice *_this, const char *mi
|
||||||
extern SDL_bool SDL_HasInternalClipboardData(SDL_VideoDevice *_this, const char *mime_type);
|
extern SDL_bool SDL_HasInternalClipboardData(SDL_VideoDevice *_this, const char *mime_type);
|
||||||
|
|
||||||
/* General purpose clipboard text callback */
|
/* General purpose clipboard text callback */
|
||||||
const void *SDL_ClipboardTextCallback(void *userdata, const char *mime_type, size_t *size);
|
const void * SDLCALL SDL_ClipboardTextCallback(void *userdata, const char *mime_type, size_t *size);
|
||||||
|
|
||||||
#endif /* SDL_clipboard_c_h_ */
|
#endif /* SDL_clipboard_c_h_ */
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue