This commit fixes a regression introduced by c44fa5bb
The evdev backend currently uses high_res_hwheel to select the
normalization denominator for both horizontal and vertical wheel
events.
This causes devices which advertise REL_WHEEL_HI_RES but not
REL_HWHEEL_HI_RES to report vertical wheel movement 120 times
larger than intended.
Use the corresponding high-resolution capability independently for
each axis, restoring the behavior before c44fa5bb.
SDL_QueryGPUFence is documented to return true when the fence is signaled (complete). Since 514b26e it returns METAL_INTERNAL_IsFenceBusy directly, so it returns true when the fence is still busy, breaking usage of SDL_AcquireGPUSwapchainTexture.
- Add VID/PID and button mapping for Tarantula 8K
- Remove outdated joystick dead zone algorithm, pass raw data directly
- Correct naming of extension keys
These functions were declared in the SDL_waylanddatamanager.h header, but the implementations were in SDL_waylandevents.c
Move the implementations to the SDL_waylanddatamanager.c source file, where one would expect to find them.
Some tiling compositors will set the maximized state and set their own, preferred dimensions, even if the window is flagged as non-resizable, and the min/max limits are properly set. The spec says that the configure size must be obeyed in the maximized state, so, in these odd cases, use a viewport to make the content fit within the configure dimensions.
When HAVE_GETRESUID/HAVE_GETRESGID are not defined, SDL_waylandvideo.c defines
static inline fallbacks using the libc names. glibc declares both functions
non-static in <unistd.h>, so on a toolchain where the feature checks fail while
those declarations are still visible the file fails to compile:
error: static declaration of 'getresuid' follows non-static declaration
Give the fallbacks SDL-private names and call those, so a fallback can never
collide with a libc declaration. Also fixes the fallback getresgid() taking
uid_t* parameters where it should take gid_t*.
Ensure that references to the clipboard being held by other seats are cleared when new data is being set, or some seats may hold references to invalid data and callbacks.
Sending a nil selection followed by immediately destroying the selection offer is redundant, and avoiding intermediate nil offers helps some clipboard managers avoid potential race conditions.
The clipboard code often had excessive and unnecessary error checking (e.g. checking if the video backed was initialized, when there is no way that path would be hit if it wasn't), overly complicated some operations, and had several cases where things can be C99-ified. Clean things up a bit to make it easier to read and debug.