Commit Graph

10466 Commits

Author SHA1 Message Date
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
Sam Lantinga d3b2e62e80 Merge commit 'd4e6047e3cc73698a0d6b3b4a2ce7b9b5e025b2f' into main 2022-06-29 17:25:43 -07:00
Sam Lantinga 302a863ad3 Merge commit '7a02dcf3e662d2a087908a8b378872aee8c83587' into main 2022-06-29 17:25:41 -07:00
Sam Lantinga e022b12a47 Merge commit 'cddf095a16263734bef07cefbbac1a42bf70d171' into main 2022-06-29 17:25:39 -07:00
Sam Lantinga c2ba2e230e Merge commit 'b6f1c91862ae5b260f80cca2968cd9baefe41523' into main 2022-06-29 17:25:37 -07:00
Sam Lantinga ca18ab00a7 Merge commit 'cbd01874759dad39718e1496d241c4ae5eceaff1' into main 2022-06-29 17:25:35 -07:00
Sam Lantinga c75e780f8f Merge commit 'f25b4b27743d4b018393a3083e9d9061ab5ce07a' into main 2022-06-29 17:25:33 -07:00
Sam Lantinga 48f2d2f832 Merge commit '6c536afdb7bdc9cece4152c7e1f9a18306976b46' into main 2022-06-29 17:25:31 -07:00
Sam Lantinga 241755f4f0 Merge commit 'e4a80875519617775184e9f6be5ede51772850fa' into main 2022-06-29 17:25:30 -07:00
Sam Lantinga 9bc2021c90 Merge commit '972391763790134796a353487faeadd451ccc046' into main 2022-06-29 17:25:28 -07:00
Sam Lantinga d800f95dca Merge commit '0a9a0a79e0a40a2843c1f6d33f7fa45bb1042fc0' into main 2022-06-29 17:25:26 -07:00
Sam Lantinga 2170301c0b Merge commit '3b191580c392b7a2f7ee7c8a586020817dc7dc05' into main 2022-06-29 17:25:24 -07:00
Sam Lantinga 21196f4237 Merge commit '314bb5a1ed1a90276597b9aefef225a7c5027845' into main 2022-06-29 17:25:22 -07:00
Sam Lantinga b733e38c3a Merge commit '7fd46ec581d45ec3fea3fcfe226bbc2ae824fc7c' into main 2022-06-29 17:25:20 -07:00
Sam Lantinga 3d10cc152e Merge commit '84d69da4e173365ddfdfe0a77ac5bc79b25f1972' into main 2022-06-29 17:25:18 -07:00
Sam Lantinga a4c1cf732e Merge commit '1f3ae75228e46d440e98bc13bbb8ffcfafcee920' into main 2022-06-29 17:25:16 -07:00
Sam Lantinga cc3563c76c Merge commit 'b2f07d94d2627b57226543981c5210a3f7642f4e' into main 2022-06-29 17:25:14 -07:00
Sam Lantinga ebb191f34d Merge commit 'ebe4f47f2b2e97deed78faa6c3e90ff51cd499a4' into main 2022-06-29 17:25:12 -07:00
Sam Lantinga e9908d840b Merge commit '51c6488f97f98aa3d216092c01d9601008be0fbf' into main 2022-06-29 17:25:10 -07:00
Sam Lantinga af53db1105 Merge commit 'fa39f73552dc9dfd6a6a45aa499ac213f1907ef0' into main 2022-06-29 17:25:08 -07:00
Sam Lantinga dab3ba1fca Merge commit '787dc260a8a788a0d2319fe76f7756e0bc607e03' into main 2022-06-29 17:25:06 -07:00
Sam Lantinga 892518f8f7 Merge commit '76f40e2b3b685b18a7f8db64bf425d3c87ddc896' into main 2022-06-29 17:25:04 -07:00
Sam Lantinga b85118f565 Merge commit 'ca30936314e1867c143475ea278988f82af95155' into main 2022-06-29 17:25:03 -07:00
Sam Lantinga 43f55e6f0a Merge commit '118a2189fb203dedc274848833b5431273cb1db5' into main 2022-06-29 17:25:01 -07:00
Sam Lantinga 02cbf8b702 Merge commit 'bd49696133eded6f441b20391b5bb4376b3834d8' into main 2022-06-29 17:24:59 -07:00
Sam Lantinga 808edbcdca Merge commit '6dcb2868b03b21a4cfacf0d5804ee07cfde0a0c7' into main 2022-06-29 17:24:57 -07:00
Sam Lantinga 88816d65d5 Merge commit '78a37516593dbcedb2b0d1a5177f37c348dbb528' into main 2022-06-29 17:24:55 -07:00
Sam Lantinga 233e88f707 Merge commit 'c61367c2731dca1e7ea0e881f69d96317c0aaaab' into main 2022-06-29 17:24:53 -07:00
Sam Lantinga 048da613a5 Merge commit '965c16453785279d921b584c92f14bd0ef034730' into main 2022-06-29 17:24:51 -07:00
Sam Lantinga 4ff3d844ad Merge commit '3617691fe0cb3b29ffcdeb5567d85126de91ba15' into main 2022-06-29 17:24:49 -07:00