From ad9dcdbbce4adf82b9af9cd0eef812ca3d49d24b Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Sat, 4 Nov 2023 09:58:35 -0700 Subject: [PATCH] Clarify that you should use the other field when reading the event --- include/SDL3/SDL_events.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/SDL3/SDL_events.h b/include/SDL3/SDL_events.h index 312452444..ad87c5ccb 100644 --- a/include/SDL3/SDL_events.h +++ b/include/SDL3/SDL_events.h @@ -268,7 +268,7 @@ typedef struct SDL_TextEditingEvent Uint64 timestamp; /**< In nanoseconds, populated using SDL_GetTicksNS() */ SDL_WindowID windowID; /**< The window with keyboard focus, if any */ char *text; /**< The editing text */ - char short_text[SDL_TEXTEDITINGEVENT_TEXT_SIZE]; /**< Memory space for short editing text */ + char short_text[SDL_TEXTEDITINGEVENT_TEXT_SIZE]; /**< Memory space for short editing text, use 'text' instead */ Sint32 start; /**< The start cursor of selected editing text */ Sint32 length; /**< The length of selected editing text */ } SDL_TextEditingEvent; @@ -524,7 +524,7 @@ typedef struct SDL_DropEvent float x; /**< X coordinate, relative to window (not on begin) */ float y; /**< Y coordinate, relative to window (not on begin) */ char *data; /**< The text for SDL_EVENT_DROP_TEXT and the file name for SDL_EVENT_DROP_FILE, NULL for other events */ - char short_data[SDL_DROPEVENT_DATA_SIZE]; /**< Memory space for short data */ + char short_data[SDL_DROPEVENT_DATA_SIZE]; /**< Memory space for short data, use 'data' instead */ } SDL_DropEvent; /**