clipboard: SDL_GetClipboardText() now follows the SDL_GetStringRule.

Reference Issue #10229.
This commit is contained in:
Ryan C. Gordon 2024-07-15 14:00:52 -04:00
parent 3bc81a81f5
commit 158fc459f1
6 changed files with 21 additions and 25 deletions

View file

@ -2278,13 +2278,12 @@ int SDLTest_CommonEventMainCallbacks(SDLTest_CommonState *state, const SDL_Event
SDLTest_PasteScreenShot();
} else {
/* Ctrl-V paste awesome text! */
char *text = SDL_GetClipboardText();
const char *text = SDL_GetClipboardText();
if (*text) {
SDL_Log("Clipboard: %s\n", text);
} else {
SDL_Log("Clipboard is empty\n");
}
SDL_free(text);
}
}
break;