mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-08 12:28:14 +00:00
Don't cleanup clipboard in SDL_SendClipboardUpdate on Wayland
This commit is contained in:
@@ -30,7 +30,10 @@ void SDL_SendClipboardUpdate(bool owner, char **mime_types, size_t num_mime_type
|
|||||||
{
|
{
|
||||||
if (!owner) {
|
if (!owner) {
|
||||||
// Clear our internal clipboard contents when external clipboard is set
|
// Clear our internal clipboard contents when external clipboard is set
|
||||||
SDL_CancelClipboardData(0);
|
// Wayland: https://github.com/libsdl-org/SDL/issues/12152
|
||||||
|
if (SDL_strcmp(SDL_GetCurrentVideoDriver(), "wayland") != 0)
|
||||||
|
SDL_CancelClipboardData(0);
|
||||||
|
|
||||||
SDL_SaveClipboardMimeTypes((const char **)mime_types, num_mime_types);
|
SDL_SaveClipboardMimeTypes((const char **)mime_types, num_mime_types);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user