pen: Send virtual mouse and touch events for pen input.

Fixes #11948.
This commit is contained in:
Ryan C. Gordon 2025-01-14 23:30:10 -05:00
parent 169c8d5140
commit dabc93a631
8 changed files with 168 additions and 32 deletions

View file

@ -4185,6 +4185,36 @@ extern "C" {
*/
#define SDL_HINT_ASSERT "SDL_ASSERT"
/**
* A variable controlling whether pen events should generate synthetic mouse
* events.
*
* The variable can be set to the following values:
*
* - "0": Pen events will not generate mouse events.
* - "1": Pen events will generate mouse events. (default)
*
* This hint can be set anytime.
*
* \since This hint is available since SDL 3.2.0.
*/
#define SDL_HINT_PEN_MOUSE_EVENTS "SDL_PEN_MOUSE_EVENTS"
/**
* A variable controlling whether pen events should generate synthetic touch
* events.
*
* The variable can be set to the following values:
*
* - "0": Pen events will not generate touch events.
* - "1": Pen events will generate touch events. (default)
*
* This hint can be set anytime.
*
* \since This hint is available since SDL 3.2.0.
*/
#define SDL_HINT_PEN_TOUCH_EVENTS "SDL_PEN_TOUCH_EVENTS"
/**
* An enumeration of hint priorities.