Commit Graph

10495 Commits

Author SHA1 Message Date
Sam Lantinga 9221840280 Merge commit '2a25b69ba580ff63ede93f2b19fa1bca09dab484' into main 2022-07-05 21:41:15 -07:00
Sam Lantinga c218b55c67 Merge commit '0a600b1df45558c16812995aa2c03f0b5f636afb' into main 2022-07-05 21:41:13 -07:00
Sam Lantinga 89c393306d Merge commit 'cd79e9c4e25ffd15010953b15ae8cbc25b7e7a90' into main 2022-07-05 21:41:11 -07:00
Sam Lantinga 23ff1c605a Merge commit 'f317d619ccd22e60cebf1b09d716d3985359c981' into main 2022-07-05 21:41:09 -07:00
Sam Lantinga 95405d9625 Merge commit '0025621b8064f5c72561d5d7b7a1fbdde860c236' into main 2022-07-05 21:39:44 -07:00
Sam Lantinga 4615494f9d Merge commit '391dd0d94b625ae9f7edec2b7514a2f6ba9fb670' into main 2022-07-05 21:39:42 -07:00
Sam Lantinga 85d6d83b6c Merge commit '89624485ccffa9e9b9f1743d431034297daaf251' into main 2022-07-05 21:39:40 -07:00
Sam Lantinga a9a79ddfb1 Merge commit 'e9d5060c4c2df66e8d4ef4f748f80e8ef32fc233' into main 2022-07-05 21:39:38 -07:00
Sam Lantinga 91c7329ce1 Merge commit '209f457ea4eed6a2a3816f42049a17101c049d9c' into main 2022-07-05 21:39:36 -07:00
Sam Lantinga acc03716ea Merge commit 'bdbf90e3fc27c123e699c03f54de3e35e51861dc' into main 2022-07-05 21:39:35 -07:00
Sam Lantinga 6d3ce729a6 Merge commit '7ac5d616f3732b4d98010331d2ae0a24f883092d' into main 2022-07-05 21:39:33 -07:00
Sam Lantinga 7ef298f7c7 Merge commit '37a517dc36b7ba8f703c82a408bef6e44e5786ba' into main 2022-07-05 21:39:31 -07:00
Sam Lantinga 6b0e1adfe9 Merge commit '78089e6598240178b62d6720eec041cc698a5e7c' into main 2022-07-05 21:39:29 -07:00
Sam Lantinga fbc9800304 Merge commit '3e114872e842879c048b2a7808f2cdbfeb2228fe' into main 2022-07-05 21:39:27 -07:00
Sam Lantinga d514f24839 Merge commit '4f732197947d39cf13b4e3de1811d9bcace3798c' into main 2022-07-05 21:39:25 -07:00
Sam Lantinga eaeaf55fc2 Merge commit '24251fb5442296b8066ccc7af6cda430bf2017db' into main 2022-07-05 21:39:23 -07:00
Eddy Jansson ad0b91302d android: Add missing entries to SDL_category_prefixes table.
Add static assert so this shouldn't happen in the future.

Fixes #5883
2022-07-05 17:50:19 -07:00
Chris Mumford 98411c0d33 Added include: libkern/OSAtomic.h
When building on macOS without gcc (e.g. clang) where HAVE_GCC_ATOMICS
is not defined, `SDL_AtomicTryLock` will call
`OSAtomicCompareAndSwap32Barrier` which is not yet declared.
Including OSAtomic.h on OSX resolves this error/warning:

    SDL_spinlock.c:125:12: error: implicit declaration of function
      'OSAtomicCompareAndSwap32Barrier' is invalid in
      C99 [-Werror,-Wimplicit-function-declaration]
        return OSAtomicCompareAndSwap32Barrier(0, 1, lock);

This was reported in issue #3885 but marked Invalid and closed - possibly
because the default CMake build uses gcc instead of clang.
2022-07-05 07:50:57 -07:00
SDL Wiki Bot 6187edd41e Sync SDL wiki -> header 2022-07-04 23:57:05 +00:00
Ryan C. Gordon fdb86b8266
x11: Don't try to use XInput2 multitouch if not supported.
Fixes #5889.
2022-07-04 12:48:32 -04:00
rohlem b085c18251 make SDL_SetTextInputRect take a pointer to const
The documentation doesn't state that the argument is ever modified,
and no implementation does so currently.
This is a non-breaking change to guarantee as much to callers.
2022-07-04 09:38:01 -07:00
Dav999-v 51f75b8b30 Fix fallback implementations of SDL_strchr and SDL_strrchr for '\0'
strchr and strrchr return a pointer to the first/last occurrence of a
character in a string, or NULL if the character is not found. According
to the C standard, the final null terminator is part of the string, and
it should thus be possible to get a pointer to the final null with
these functions. The fallback implementations of SDL_strchr and
SDL_strrchr would always return NULL if trying to find '\0', and this
commit fixes that.
2022-07-04 11:10:26 -04:00
SDL Wiki Bot fcb99d7830 Sync SDL wiki -> header 2022-07-04 13:42:05 +00:00
chalonverse 85bbf8eec9 Fixed coment after #endif 2022-07-03 15:22:30 -04:00
Francisco Javier Trujillo Mata 643f9e56d0 Rename folder created in test_filesystem 2022-07-03 09:24:55 -07:00
Francisco Javier Trujillo Mata 7d7c5b803c Improving mkdir creating parents folder 2022-07-03 09:23:34 -07:00
Anthony Heathcoat 2a25b69ba5 Check if GNC is defined before checking its value to solve warns in msvc 2022-07-03 00:56:09 -07:00
Cameron Cawley 0a600b1df4
Merge testguid into testautomation (#5873) 2022-07-01 16:27:51 -07:00
Sam Lantinga cd79e9c4e2 Removed comment text that looks like doxygen commands 2022-07-01 14:04:07 -07:00
chalonverse f317d619cc
Xbox GDKX support (#5869)
* Xbox GDK support (14 squashed commits)

* Added basic keyboard testing

* Update readme

* Code review fixes

* Fixed issue where controller add/removal wasn't working (since the device notification events don't work on Xbox, have to use the joystick thread to poll XInput)
2022-07-01 13:59:14 -07:00
Cameron Cawley 0025621b80 Add a default URL in testurl 2022-07-01 13:54:17 -07:00
Sam Lantinga 391dd0d94b Don't spin as quickly as possible in the checkkeys rendering loop 2022-07-01 13:35:41 -07:00
Sam Lantinga 89624485cc Updated the test bitmap font to cover the Latin-1 character set
Based on Marcel Sondaar's font8_8.asm, in the public domain
2022-07-01 13:32:56 -07:00
Sam Lantinga e9d5060c4c checkkeys will now render text that is input
Also added test functions for multi-line debug text display

Currently this only supports ASCII, as the font doesn't have the correct Latin-1 characters
2022-07-01 12:56:47 -07:00
Sam Lantinga 209f457ea4 Generate backspaces for the text we're going to replace when committing text 2022-07-01 10:13:19 -07:00
Sam Lantinga bdbf90e3fc on-screen keyboard newline is reported as an Enter key 2022-07-01 09:17:30 -07:00
Sam Lantinga 7ac5d616f3 Fixed backspace being delivered after committed text on Android 12
Testing:
Enter "hello ", followed by "?" - the events generated are:
: commitText hello
: Key pressed :  scancode 11 = H, keycode 0x00000068 = H  modifiers: (none)
: Key released:  scancode 11 = H, keycode 0x00000068 = H  modifiers: (none)
: Key pressed :  scancode 8 = E, keycode 0x00000065 = E  modifiers: (none)
: Key released:  scancode 8 = E, keycode 0x00000065 = E  modifiers: (none)
: Key pressed :  scancode 15 = L, keycode 0x0000006C = L  modifiers: (none)
: Key released:  scancode 15 = L, keycode 0x0000006C = L  modifiers: (none)
: Key pressed :  scancode 15 = L, keycode 0x0000006C = L  modifiers: (none)
: Key released:  scancode 15 = L, keycode 0x0000006C = L  modifiers: (none)
: Key pressed :  scancode 18 = O, keycode 0x0000006F = O  modifiers: (none)
: Key released:  scancode 18 = O, keycode 0x0000006F = O  modifiers: (none)
: Key pressed :  scancode 44 = Space, keycode 0x00000020 = Space  modifiers: (none)
: Key released:  scancode 44 = Space, keycode 0x00000020 = Space  modifiers: (none)
: INPUT Text (\x68\x65\x6c\x6c\x6f\x20): "hello "
: finishComposingText
: deleteSurroundingText 1 / 0
: Key pressed :  scancode 42 = Backspace, keycode 0x00000008 = Backspace  modifiers: (none)
: Key released:  scancode 42 = Backspace, keycode 0x00000008 = Backspace  modifiers: (none)
: commitText ?
: Key pressed :  scancode 225 = Left Shift, keycode 0x400000E1 = Left Shift  modifiers: LSHIFT
: Key pressed :  scancode 56 = /, keycode 0x0000002F = /  modifiers: (none)
: Key released:  scancode 56 = /, keycode 0x0000002F = /  modifiers: (none)
: Key released:  scancode 225 = Left Shift, keycode 0x400000E1 = Left Shift  modifiers: (none)
: INPUT Text (\x3f): "?"
: setComposingText , at 1
: EDIT Text (): ""

Previously, the backspace would be delivered after the "?"
2022-07-01 08:58:08 -07:00
Sam Lantinga 37a517dc36 Re-enable IME text input on Android
In my testing, this results in text edit events followed by text input events. Any ASCII characters will generate scancode events based on a hypothetical US keyboard layout.

Fixes https://github.com/libsdl-org/SDL/issues/3377
2022-07-01 08:33:31 -07:00
Cameron Cawley 78089e6598 Remove unused internal header SDL_sysevents.h 2022-07-01 07:39:48 -07:00
Cameron Gutman 3e114872e8 joystick: Fix redetection of HIDAPI joysticks after reinitializing
The HIDAPI joystick driver doesn't properly reset the change counter
it uses to track if re-enumeration is needed when the joystick
subsystem is quit and then reinitialized.

The first SDL_Init(SDL_INIT_JOYSTICK) will result in the expected
HIDAPI joysticks appearing, but subsequent calls will result in no
joysticks being enumerated until another HIDAPI joystick is added
or removed from the system.
2022-06-30 20:43:14 -07:00
chalonverse 4f73219794 Fixed D3D12 renderer not working with batching, and got rid of the vertex buffer size limit 2022-06-30 03:41:17 -07:00
Sam Lantinga 24251fb544 Fixed checkkeys closing when tapping the screen on a phone 2022-06-29 17:40:45 -07:00
Sam Lantinga 0ad65277ce Refactored code to send scancodes for an ASCII on-screen keyboard key 2022-06-29 17:26:09 -07:00
Sam Lantinga b51330ab4b Merge commit '0ad65277ce7ca025438694caf39f83b80d4eea4c' into main 2022-06-29 17:25:57 -07:00
Sam Lantinga 47c4324920 Merge commit 'a054a5f7f2dde31431cf890e421886faacdf5f54' into main 2022-06-29 17:25:55 -07:00
Sam Lantinga d54931e287 Merge commit '6a2e6c82a0764a00123447d93999ebe14d509aa8' into main 2022-06-29 17:25:53 -07:00
Sam Lantinga f0313044bd Merge commit 'db7dfece16565352224ac534d6975b85f12d962f' into main 2022-06-29 17:25:51 -07:00
Sam Lantinga 55840423aa Merge commit '43555bd1a9f8188b6f83a7c7d45861a35df6a54b' into main 2022-06-29 17:25:49 -07:00
Sam Lantinga 11c6c8c06a Merge commit '1d1fb95a61e6815ba08cd25ab954165a4d693e96' into main 2022-06-29 17:25:47 -07:00
Sam Lantinga 3adf6bacd3 Merge commit 'f815580dde2de9667af5ca8b43f9590f2fac1aab' into main 2022-06-29 17:25:45 -07:00