Add new verbosity level for logging of SDL_SysWMEvents

Now logged only if SDL_HINT_EVENT_LOGGING is set to "3" or above.
This commit is contained in:
Susko3 2022-05-03 00:11:44 +02:00 committed by Sam Lantinga
parent d1a3981bf8
commit 6150245d65
2 changed files with 21 additions and 9 deletions

View file

@ -392,13 +392,14 @@ extern "C" {
#define SDL_HINT_ENABLE_STEAM_CONTROLLERS "SDL_ENABLE_STEAM_CONTROLLERS"
/**
* \brief A variable controlling whether SDL logs all events pushed onto its internal queue.
* \brief A variable controlling verbosity of the logging of SDL events pushed onto the internal queue.
*
* This variable can be set to the following values:
* This variable can be set to the following values, from least to most verbose:
*
* "0" - Don't log any events (default)
* "1" - Log all events except mouse and finger motion, which are pretty spammy.
* "2" - Log all events.
* "1" - Log most events (other than the really spammy ones).
* "2" - Include mouse and finger motion events.
* "3" - Include SDL_SysWMEvent events.
*
* This is generally meant to be used to debug SDL itself, but can be useful
* for application developers that need better visibility into what is going