bruvzg
0103af1ddd
Fix MSVC warnings, rename shadowed variables, fix uninitialized values, change warnings=all to use /W4.
2022-10-07 11:32:33 +03:00
Fabio Alessandrelli
0fe0505f77
[Web] Add PS3 gamepad mapping for FF+Linux.
2022-10-03 13:06:50 +02:00
Jiri Suchan
c5bd2f9dce
ci: add Python static analysis check via mypy
2022-09-30 19:03:17 +07:00
Rémi Verschelde
b33460c6ca
Sync controller mappings DB with SDL2 community repo
...
Synced with gabomdq/SDL_GameControllerDB@81ddc73d17
2022-09-27 23:48:25 +02:00
Rémi Verschelde
f3d763011f
Merge pull request #63109 from OverloadedOrama/fix-input-event-action
...
Fix `InputEventAction`'s `is_match` method ignoring `exact_match` parameter
2022-09-25 11:06:38 +02:00
bruvzg
6f4d233062
Fix key mapping changes when moving from macOS to other platform
...
Removes separate `Command` key (use `Meta` instead).
Adds an event flag to automatically remap `Command` <-> `Control` (cannot be set alongside `Control` or `Meta`).
2022-09-07 18:45:35 +02:00
Andres Hernandez
9054399900
Updated gamecontrollerdb.txt to latest to include new mappings for various controllers, including Xbox One, Nintendo Switch, Steam Deck, and 8BitDo
2022-09-05 22:14:59 -07:00
Rémi Verschelde
8812f0c896
Merge pull request #64444 from timothyqiu/action-completion
...
Fix action name completion for `Input`
2022-09-01 08:20:20 +02:00
Fabio Alessandrelli
d20b32186f
[Web] Rename JavaScript platform to Web.
...
Also rename export name from "HTML5" to "Web".
2022-08-29 11:52:00 +02:00
Rémi Verschelde
d0a2a4c981
Merge pull request #64531 from madmiraal/fix-63972-2
...
Fix axis mapped to DPad buttons not releasing opposite button
2022-08-24 20:10:29 +02:00
kobewi
1abdffe7a0
Replace Array return types with TypedArray 2
2022-08-23 23:21:32 +02:00
Rémi Verschelde
3f3ade9e5b
Merge pull request #64732 from RandomShaper/input_is_final
...
Consolidate the fact that `Input` is meant to be final
2022-08-23 08:53:49 +02:00
Yuri Sizov
1a24c9e14b
Make _validate_property
a multilevel method
2022-08-22 18:35:11 +03:00
Pedro J. Estébanez
99edd4b43d
Consolidate the fact that Input
is meant to be final
...
This reverts #38034 and removes the `iteration()` method.
2022-08-22 14:37:25 +02:00
Marcel Admiraal
61be617571
Fix axis mapped to DPad buttons not releasing opposite button
2022-08-17 09:12:47 +01:00
Haoyu Qiu
660c700f9c
Fix action name completion for Input
2022-08-15 23:28:49 +08:00
Haoyu Qiu
e061b1cc3c
Use %s for bool value in vformat
2022-08-07 09:57:09 +08:00
Rémi Verschelde
86647c9e42
Sync controller mappings DB with SDL2 community repo
...
Synced with gabomdq/SDL_GameControllerDB@4896d2de6b
2022-08-05 02:59:03 +02:00
Fabio Alessandrelli
55845bac26
Fix some array size function definition mismatch.
2022-08-04 13:06:17 +02:00
Rémi Verschelde
90019676b0
Code quality: Fix header guards consistency
...
Adds `header_guards.sh` bash script, used in CI to validate future
changes. Can be run locally to fix invalid header guards.
2022-07-25 11:17:40 +02:00
bruvzg
8823eae328
Rename OSX to macOS and iPhoneOS to iOS.
2022-07-21 09:37:52 +03:00
Rémi Verschelde
b70e4fc0f3
Sync controller mappings DB with SDL2 community repo
...
Synced with gabomdq/SDL_GameControllerDB@880abd09c9
2022-07-18 15:42:48 +02:00
Emmanouil Papadeas
38b51942d6
Fix InputEventAction
's is_action
method ignoring exact_match
parameter
2022-07-17 17:20:37 +03:00
Rémi Verschelde
344b42703b
Merge pull request #62212 from hansemro/eraser-detect-4
...
Add inversion/eraser-end property for tablet pens
2022-07-04 21:48:19 +02:00
Hansem Ro
6dcc9d1131
[macOS, Windows, X11] Add stylus inverted/eraser support to
...
InputEventMouseMotion event
2022-07-04 10:36:53 -07:00
Rémi Verschelde
00b3822306
Input: Re-enable input accumulation by default
...
I turned it off by mistake in #38697 .
See also #62664 for details on this boolean's complex history :)
2022-07-03 12:16:16 +02:00
Marco F
0efa5d4cbd
Input: Make get_action_raw_strength
print error when the action doesn't exist
2022-06-28 15:58:26 +02:00
FireForge
4678736a39
Add suffixes to all nodes and resources
2022-06-11 09:41:05 -05:00
Rémi Verschelde
ecde7ce834
Merge pull request #61669 from fire-forge/input
...
Make Input `mouse_mode` and `use_accumulated_input` properties
2022-06-04 15:52:34 +02:00
FireForge
f16c33fff6
Make Input mouse_mode and use_accumulated_input properties
2022-06-03 14:19:38 -05:00
Raul Santos
3e53afd52c
Add array element type to get_connected_joypads
2022-06-03 20:37:46 +02:00
reduz
45af29da80
Add a new HashSet template
...
* Intended to replace RBSet in most cases.
* Optimized for iteration speed
2022-05-20 22:40:38 +02:00
reduz
746dddc067
Replace most uses of Map by HashMap
...
* Map is unnecessary and inefficient in almost every case.
* Replaced by the new HashMap.
* Renamed Map to RBMap and Set to RBSet for cases that still make sense
(order matters) but use is discouraged.
There were very few cases where replacing by HashMap was undesired because
keeping the key order was intended.
I tried to keep those (as RBMap) as much as possible, but might have missed
some. Review appreciated!
2022-05-16 10:37:48 +02:00
reduz
8b7c7f5a75
Add a new HashMap implementation
...
Adds a new, cleaned up, HashMap implementation.
* Uses Robin Hood Hashing (https://en.wikipedia.org/wiki/Hash_table#Robin_Hood_hashing ).
* Keeps elements in a double linked list for simpler, ordered, iteration.
* Allows keeping iterators for later use in removal (Unlike Map<>, it does not do much
for performance vs keeping the key, but helps replace old code).
* Uses a more modern C++ iterator API, deprecates the old one.
* Supports custom allocator (in case there is a wish to use a paged one).
This class aims to unify all the associative template usage and replace it by this one:
* Map<> (whereas key order does not matter, which is 99% of cases)
* HashMap<>
* OrderedHashMap<>
* OAHashMap<>
2022-05-12 11:21:29 +02:00
Rémi Verschelde
30fbb8964d
Sync controller mappings DB with SDL2 community repo
...
Synced with gabomdq/SDL_GameControllerDB@b7d126eb71
2022-05-05 14:12:55 +02:00
Hugo Locurcio
180e5d3028
Remove RES
and REF
typedefs in favor of spelled out Ref<>
...
These typedefs don't save much typing compared to the full `Ref<Resource>`
and `Ref<RefCounted>`, yet they sometimes introduce confusion among
new contributors.
2022-05-03 01:43:50 +02:00
Rémi Verschelde
c273ddc3ee
Style: Partially apply clang-tidy's cppcoreguidelines-pro-type-member-init
...
Didn't commit all the changes where it wants to initialize a struct
with `{}`. Should be reviewed in a separate PR.
Option `IgnoreArrays` enabled for now to be conservative, can be
disabled to see if it proposes more useful changes.
Also fixed manually a handful of other missing initializations / moved
some from constructors.
2022-05-02 16:28:25 +02:00
Paulb23
5e4e4967fe
Use Input::push_input for tests plus extra mouse testing
2022-04-22 17:39:12 +01:00
Rémi Verschelde
bd9ba4bd10
Merge pull request #60208 from Magorx/input-set-custom-mouse-cursor-fix
...
Added p_shape check to avoid engine crash in DisplayServer
2022-04-14 00:12:51 +02:00
KingCakeTheFruity
29a2809d21
Added p_shape check to avoid engine crush
2022-04-13 14:50:30 +03:00
bruvzg
f851c4aa33
Fix some issues found by cppcheck.
2022-04-06 14:34:37 +03:00
Rémi Verschelde
7119d355eb
String: Remove TTR and DTR defines in non-tools build
...
This ensures we don't use TTR in runtime code, as it's specifically meant
to source translations for the editor.
2022-03-28 20:26:35 +02:00
Markus Sauermann
0494e024d8
Rename warp mouse functions to warp_mouse
2022-03-27 14:12:01 +02:00
Marcel Admiraal
ea20049afc
Ensure minimum modifiers are pressed when matching actions
2022-03-20 08:02:54 +00:00
Haoyu Qiu
d1ca29cd8c
Remove TTRC()
with empty string
...
Fixes "duplicate message definition" when extracting messages.
2022-03-02 17:02:10 +08:00
Rémi Verschelde
e3d89a76f7
Sync controller mappings DB with SDL2 community repo
...
Synced with gabomdq/SDL_GameControllerDB@94b76208bc
2022-02-20 12:20:17 +01:00
Powerbyte7
b8a7ea034c
[HTML5] Add Stadia controller to database
...
Add web support for the Stadia controller.
2022-02-19 23:01:41 +01:00
Rémi Verschelde
b8b4580448
Style: Cleanup single-line blocks, semicolons, dead code
...
Remove currently unused implementation of TextureBasisU, could be re-added
later on if needed and ported.
2022-02-16 14:06:29 +01:00
Rémi Verschelde
bf0253bab9
Merge pull request #56764 from madmiraal/fix-45592-2
2022-02-03 18:10:30 +01:00
Nathan Franke
8a0a3accee
simplify formatting scripts, add a clang-tidy script, and run clang-tidy
2022-01-29 04:41:03 -06:00