meyraud705
c6ec999869
Set udev class for accelerometer
2024-03-03 08:40:24 -08:00
Ryan C. Gordon
e61dfe405f
android: Fixed dead URL in comment.
2024-02-26 11:28:32 -05:00
Sam Lantinga
fee140bdfe
Added the option for GameInput support to the Win32 SDL build
...
GameInput is designed to be used by Win32 C applications, so no need to restrict it to the GDK build.
2024-02-17 14:07:42 -08:00
Nikita Krapivin
534f753e20
GameInput backend for SDL (Gamepad-only for now)
2024-02-17 11:33:51 -08:00
Ozkan Sezer
aae2d22852
Check the SDL_VIDEO_RENDER_??? macros with #if instead of #ifdef
...
Allows users to disable them by defining them as 0.
Closes https://github.com/libsdl-org/SDL/issues/8996
(manual port of https://github.com/libsdl-org/SDL/pull/9063 to SDL3.0)
2024-02-15 20:55:02 +03:00
Ryan C. Gordon
bc984f78bf
android: Remove blocking permission request code. Async only in SDL3!
...
(this actually still blocks at our internal points of usage, though, for
replacement at a later time.)
2024-02-13 12:06:51 -05:00
Ryan C. Gordon
af61cfd5e0
android: Added SDL_AndroidRequestPermissionAsync.
2024-02-13 12:06:51 -05:00
Sam Lantinga
9ce7fe2848
Removed SDL_HINT_ACCELEROMETER_AS_JOYSTICK
...
Sensors are a first-class object in SDL and we haven't gotten any feedback that this feature is useful these days.
Closes https://github.com/libsdl-org/SDL/pull/7879
2024-02-12 09:54:33 -08:00
Sam Lantinga
cacac6cc34
Updated structure and field names for consistency
...
Type names are camel case and field names are snake case except for fields ending in id, which are capitalized.
Fixes https://github.com/libsdl-org/SDL/issues/6955
2024-02-11 08:27:56 -08:00
Sam Lantinga
b7c61569f8
Redefine XINPUT_CAPABILITIES_EX as an SDL typedef
...
mingw-w64 has added this from Proton (which added this from SDL), so we need to re-define it as a local symbol to avoid conflicting with mingw-w64 headers.
Fixes https://github.com/libsdl-org/SDL/issues/9031
2024-02-09 01:26:45 -08:00
Sam Lantinga
d383299779
Fixed build on older Windows SDK
2024-02-01 20:48:53 -08:00
Ryan C. Gordon
1c5bc53738
windows: Manage WideCharToMultiByte vs Windows XP.
...
Reference Issue #8666 .
2024-01-27 20:15:08 -05:00
Ryan C. Gordon
2144c2ac71
windows: Added WIN_IsWindowsXP, for extreme runtime compatibility checks.
...
Reference Issue #8666 .
2024-01-27 20:15:08 -05:00
Ryan C. Gordon
56fa22c63b
windows: OS version checks now cache results.
...
So these only have to talk to the Win32 API once per check, per process.
2024-01-27 20:15:08 -05:00
Sam Lantinga
3b55c7d1f4
Shortened SDL property names
2024-01-27 13:00:50 -08:00
Anonymous Maarten
31d133db40
Define SDL_PLATFORM_* macros instead of underscored ones ( #8875 )
2024-01-24 01:40:51 +00:00
Sam Lantinga
a71f99c71f
Fixed ambiguity between std::byte and byte in rpcndr.h
...
Fixes https://github.com/libsdl-org/SDL/issues/8911
2024-01-23 09:00:02 -08:00
Sam Lantinga
b566bfce07
Fixed warning C4152: nonstandard extension, function/data pointer conversion in expression
2024-01-19 06:49:53 -08:00
Sam Lantinga
a31dc6dfcb
Switched SDL_TouchID and SDL_FingerID to be Uint64 with 0 being an invalid value
2024-01-18 10:55:24 -08:00
Sam Lantinga
a2665f54c8
Updated the atomic API for SDL 3.0 naming conventions
...
Fixes https://github.com/libsdl-org/SDL/issues/7388
2024-01-18 04:41:34 -08:00
Sam Lantinga
a0967c017f
Fixed building with the video subsystem disabled
2024-01-17 09:24:04 -08:00
chalonverse
3a4ac15a27
Make Xbox GDK code public (and fix some GDK code rot) ( #8844 )
2024-01-14 20:31:41 -08:00
Caleb Cornett
d766f68cb3
Fix compile error with XInputOnGameInput.h
2024-01-10 12:51:27 -08:00
Sam Lantinga
1a13dae219
Added constant definitions for SDL properties
...
Fixes https://github.com/libsdl-org/SDL/issues/8622
2024-01-07 16:59:41 -08:00
Sam Lantinga
3deefa6b43
Updated documentation for SDL_HINT_SHUTDOWN_DBUS_ON_QUIT
2024-01-07 14:20:16 -08:00
Semphris
2348e8b6a2
Add hint to make SDL handle dbus_shutdown()
2024-01-07 14:11:33 -08:00
Sam Lantinga
014a63b4b5
Renamed ShowTextInput/HideTextInput to ShowScreenKeyboard/HideScreenKeyboard on Android
...
This better reflects the actual implementation and makes SDL_HINT_ENABLE_SCREEN_KEYBOARD work on Android.
Fixes https://github.com/libsdl-org/SDL/issues/8652
2024-01-06 08:11:22 -08:00
Sam Lantinga
5b3ee51c6c
Updated copyright for 2024
2024-01-01 13:15:26 -08:00
Tyson Whitehead
6daf2e943f
Try SDL_UDEV_deviceclass to detect joysticks even if in a container
...
The udev container issue is mostly to do with device notifications
and netlink. The device classification stuff just pokes file in /sys
and /run/udev. Doesn't hurt to try it first for classifying joysticks
and then fall to the guess heuristics if it fails.
2023-12-24 22:39:16 -08:00
Dimitriy Ryazantcev
08a7ca4d53
XInput: Use XInputGetCapabilitiesEx instead of fragile GuessXInputDevice
...
XInputGetCapabilitiesEx (ordinal 108) is available in XInput 1.4 that is shipped with Windows 8 and newer.
2023-12-17 08:32:10 -08:00
Sam Lantinga
8c285828e5
Fixed return value for SDL_UDEV_AddCallback()
...
Fixes https://github.com/libsdl-org/SDL/issues/8694
2023-12-15 10:06:01 -08:00
Sam Lantinga
53cda988f4
Clear any errors from a previous run
...
The error is thread-local, and the java thread may run onCreate initialization multiple times depending on the Android life cycle
2023-12-07 14:30:40 -08:00
Sam Lantinga
fe6b3ab0b0
Fixed warning C6031: Return value ignored: 'CLSIDFromString'.
2023-12-05 09:31:13 -08:00
Ryan C. Gordon
447b508a77
error: SDL's allocators now call SDL_OutOfMemory on error.
...
This means the allocator's caller doesn't need to use SDL_OutOfMemory directly
if the allocation fails.
This applies to the usual allocators: SDL_malloc, SDL_calloc, SDL_realloc
(all of these regardless of if the app supplied a custom allocator or we're
using system malloc() or an internal copy of dlmalloc under the hood),
SDL_aligned_alloc, SDL_small_alloc, SDL_strdup, SDL_asprintf, SDL_wcsdup...
probably others. If it returns something you can pass to SDL_free, it should
work.
The caller might still need to use SDL_OutOfMemory if something that wasn't
SDL allocated the memory: operator new in C++ code, Objective-C's alloc
message, win32 GlobalAlloc, etc.
Fixes #8642 .
2023-11-30 00:14:27 -05:00
Dimitriy Ryazantcev
9faa7977bd
UWP: Add support for supplementary Unicode characters input
...
Characters outside Basic Multilingual Plane (BMP) are coded as so called "surrogate pair" in two separate UTF-16 character events.
2023-11-28 12:33:21 -08:00
Dimitriy Ryazantcev
9a206adbee
UWP: Use Windows.UI.Core.CoreDispatcher.AcceleratorKeyActivated event for keyboard
...
Only in this case we can see Left Alt and Right Alt keys.
Stole the idea from DirectXTK12 repo:
https://github.com/microsoft/DirectXTK12/blob/main/Src/Keyboard.cpp
2023-11-28 11:31:19 -08:00
Sylvain
6bb40f1d8d
SDL_VideoCapture: allow add/remove device at runtime on linux
2023-11-27 16:01:10 -05:00
Ryan C. Gordon
3264e64738
SDL_RunApp: Make sure argc/argv are stable if the caller didn't define them.
...
Fixes #8246 .
2023-11-22 17:34:39 -05:00
Sam Lantinga
0907f345cb
Added property types: pointer, string, number, float
2023-11-12 10:48:38 -08:00
Sylvain Becker
04b6b2979f
Re-add SDL_assert() with non boolean ptr syntax ( #8530 )
2023-11-11 12:28:24 +03:00
Sylvain
d8600f717e
Pointer as bool (libsdl-org#7214)
2023-11-09 14:18:36 -08:00
Sam Lantinga
3ab98a3572
Removed debug print statements (thanks @stsp!)
2023-11-08 20:43:44 -08:00
Sam Lantinga
f4b61fff30
Implemented VT switching for KMSDRM on Linux
...
Fixes https://github.com/libsdl-org/SDL/issues/3844
2023-11-08 20:35:16 -08:00
Sam Lantinga
fd4a2cce9e
SDL_syswm.h has been removed and replaced with window properties
2023-11-08 12:01:48 -08:00
Sam Lantinga
a4c6b38fef
Fixed FreeBSD build
2023-11-08 07:46:02 -08:00
Sam Lantinga
d9e6dcc650
Fixed FreeBSD build
2023-11-08 04:45:29 -08:00
Sam Lantinga
7cc3e94eb2
Store the requested muted state
2023-11-08 03:36:47 -08:00
Sam Lantinga
ce9e1bd324
Don't mute the console input if we can't read the keyboard
...
This makes sure you can hit Ctrl-C if you don't have permission to access the raw keyboard device.
Fixes https://github.com/libsdl-org/SDL/issues/4812
2023-11-08 03:29:10 -08:00
Ryan C. Gordon
c53843a961
docs: Remove Doxygen \brief tags.
...
Doxygen and the wiki bridge don't need them; they'll both just use the first
line/sentence instead.
Fixes #8446 .
2023-11-06 10:26:06 -05:00
Sam Lantinga
bc3d9e99f3
Only save ibus_addr_file after we've successfully read an address from it.
...
Fixes https://github.com/libsdl-org/SDL/issues/3359
2023-11-05 22:12:37 -08:00