Commit Graph

7144 Commits

Author SHA1 Message Date
Paul Gilbert
7b721eaac1 ENGINES: Adding debugger to base Engine class 2020-02-16 13:07:19 +02:00
Bastien Bouclet
29dd15af0c KEYMAPPER: Enable remapping the keyboard modifier keys 2020-02-14 19:30:00 +01:00
Bastien Bouclet
e1358b966a 3DS: Defer texture updates when the palette changes
Fixes a performance issue with the Gob engine where the palette is
updated a large number of times during a single frame.
2020-02-14 06:21:46 +01:00
Bastien Bouclet
6218028f02 3DS: Add a note in the readme about using an older version of freetype2 2020-02-13 07:57:02 +01:00
Bastien Bouclet
fbc938f438 KEYMAPPER: Fix remapping keys with multiple modifiers pressed 2020-02-13 07:57:02 +01:00
Thanasis Antoniou
f971e1e4a8 GUI: OPTIONS: Cloud storage list populated with translated string on addCloudControls()
Resolves a bug with displaying the wrong (previous) translation when switch theme language

Previously, a translated string was stored in cloudmanager _storages config items, which would become stale if the theme language was changed.
2020-02-09 22:06:19 +02:00
Bastien Bouclet
2177e685b7 KEYMAPPER: Allow joystick half axes to be remapped 2020-02-09 08:34:16 -06:00
rsn8887
eea70a3c8c BACKEND: Allow SDL2 mapping of L2/R2, fix psp2/switch mapping 2020-02-09 08:34:16 -06:00
Bastien Bouclet
3567c4f159 BASE: Reset the keymapper on RTL with dynamic plugins enabled
When returning to the launcher with dynamic plugins enabled, the config manager
is re-created, invalidating the pointers the keymapper keeps to the
configuration domains.

Fixes #11348.
2020-02-09 07:29:43 +01:00
Bastien Bouclet
e4d17f881c 3DS: Convert RGB555 pixels to RGBA5551 when copying to the texture
It's faster than using Graphics::Surface::convertTo
2020-02-07 18:33:56 +01:00
Michael Ball
b08ab0e130 3DS: Implement dynamic graphics modes to improve performance
When launching a game, switch the graphics mode if necessary
(and by extension the pixel formats used for Graphics::Surfaces
and Sprites) to the one that most closely matches the pixel format
used in-game.

Additional Fixes:
- Fix to prevent cursor position from changing when exiting a menu.
- Fix to prevent updating of Magnification viewport position when
virtual keyboard is open.
- Cosmetic code fixes for improper whitespace and missing curly brackets.
- Remove RGB8 as a mode option because:
  1) It was already commented out in the master 3DS backend.
  2) There are currently no games that explicitly require it.

Notes:
- As these graphics modes are automatically implemented on a per-game basis, they
are meant for backend use only and are purposefully not accessible through the
Options menu.
- RGBA8 (aka RGBA8888) remains the default pixel format, being used for the launcher
menu, CLUT8, and for games which do not specify a particular format.
2020-02-07 18:33:56 +01:00
Bastien Bouclet
99b9db456a 3DS: Disable newlib buffered io and use ScummVM's implementation
Fixes #11342.
2020-02-07 18:33:56 +01:00
Bastien Bouclet
36ef316518 BACKENDS: Allow to configure the stdio buffer size 2020-02-07 18:33:56 +01:00
Bastien Bouclet
7daf2a4f5b SDL: Add back Alt+KP_ENTER as a shortcut for toggle fullscreen
Fixes #11341.
2020-02-04 08:22:02 +01:00
Thierry Crozat
98b7095527 IOS7: Fix implementation of getMillis()
The documentation indicates that it should return the number of
milliseconds since the application started. It was however using
a different reference (last boot of the device minus the sleep time)
resulting in a much bigger value than expected.
2020-02-01 22:56:25 +00:00
Thanasis Antoniou
ad046b1589 NETWORKING: Fix compiler warning about always false comparison
warning: comparison is always false due to limited range of data type [-Wtype-limits]

s is Common::String. s[i] is thus a "char". If char is signed 8bit then the comparison will indeed always be false.
2020-02-01 18:22:38 +02:00
Bastien Bouclet
81aedefad0 3DS: Fix libcurl detection 2020-02-01 09:36:10 +01:00
Bastien Bouclet
a13ce39538 3DS: Fix keymap defaults to match documentation 2020-02-01 09:36:10 +01:00
Bastien Bouclet
4ad06f476b KEYMAPPER: Do a better job at keeping track of the mouse position 2020-02-01 09:36:09 +01:00
Thanasis Antoniou
3c9741a4c3 ANDROID: Early fix for Android 9+ crash and config/save path issues 2020-01-31 17:23:15 +02:00
Eugene Sandulenko
6817478967 BACKENDS: SDL: Add override keywords 2020-01-31 12:39:23 +01:00
Eugene Sandulenko
9f168ae447 KEYMAPPER: Fix class/struct declaration mess. 2020-01-29 16:48:46 +01:00
Eugene Sandulenko
d1805a582e BACKENDS: KEYMAPPER: Hid noisy warning 2020-01-29 16:48:46 +01:00
Bastien Bouclet
161ca5285d PS3: Fix controller button name
Geometrically accurate is not good enough.
2020-01-29 16:28:36 +01:00
Bastien Bouclet
8a8336328e SDL: Fix build with SDL1 2020-01-29 09:11:37 +01:00
Bastien Bouclet
05a7ca7b76 PS3: Use the appropriate gamepad button names for the keymapper 2020-01-29 08:51:30 +01:00
Bastien Bouclet
78ab571519 3DS: Update the port to take advantage of the new keymapper 2020-01-29 08:51:30 +01:00
Bastien Bouclet
2ef7365401 KEYMAPPER: Change backend default bindings to replace keymap defaults
Previously backend defaults where added to the keymap defaults.
However, it became apparent backends need to change the default bindings
to resolve conflicts.
2020-01-29 08:51:30 +01:00
Bastien Bouclet
43184657e9 EVENTS: Disable ScummVM's source of keyboard repeat events by default
Backends can still (and do) generate such events. This works around an
issue with the keymapper where the "DOWN" event would be mapped to a
key, but the corresponding "UP" event would be mapped to another one due
to a keymap change. The keyboard repeat generation system would believe
the key to be still pressed and send a continuous stream of repeat
events.
Ideally the keymapper should be fixed to always generate matching event
pairs. However this source of an infinite stream of events still looks
like trouble waiting to happen to me. Hence disabling it by default.
2020-01-29 08:51:30 +01:00
Bastien Bouclet
cc15496e9e KEYMAPPER: Use a dropdown button to save horizontal space 2020-01-29 08:51:30 +01:00
Bastien Bouclet
5079fa9dd4 KEYMAPPER: Sort the mappings by type and id in the remap dialog 2020-01-29 08:51:29 +01:00
Bastien Bouclet
17a13c9294 KEYMAPPER: Shorten the name of some joystick inputs
So they fit more easily in the remap dialog
2020-01-29 08:51:29 +01:00
Bastien Bouclet
c001094bce KEYMAPPER: Add a button in the remap dialog to reset an entire keymap 2020-01-29 08:51:29 +01:00
Bastien Bouclet
7ecccd3b30 MOHAWK: RIVEN: Add default joystick action mappings 2020-01-29 08:51:29 +01:00
Bastien Bouclet
e973092aef KEYMAPPER: Enable remapping of the mouse buttons 2020-01-29 08:51:29 +01:00
Bastien Bouclet
519b4a57e2 KEYMAPPER: Allow engines to return multiple keymaps
The idea is that keymaps may be situational. A keymap may be always
enabled, while another one may be enabled only during combat..
2020-01-29 08:51:29 +01:00
Bastien Bouclet
426867f4bc KEYMAPPER: Give human readable descriptions to the keymaps 2020-01-29 08:51:29 +01:00
Bastien Bouclet
32174c9067 KEYMAPPER: Actions can now be bound to joystick buttons 2020-01-29 08:51:29 +01:00
Bastien Bouclet
df7ce0c55f KEYMAPPER: Rework HardwareInputSet not to allocate all possible inputs 2020-01-29 08:51:29 +01:00
Bastien Bouclet
0995f40677 MOHAWK: RIVEN: Use custom engine actions for event handing 2020-01-29 08:51:29 +01:00
Bastien Bouclet
df4bf6556c KEYMAPPER: Introduce custom engine actions
Custom engine actions are a new type of event the Keymapper can produce.
When an engine declares its keymap, it can declare it wants to receive
custom action events when the corresponding key is pressed, instead of
the originating hardware input events.

This system allows:
* Key bindings to be specified only once when declaring the keymap,
  instead of twice (when handling the events).
* To truly rebind keys in the keymaps dialog. When using traditional
  event mapping, the keymapper remaps the user keypress to the keypress
  expected by the game engine to perform the action. However, the engine
  still accepts the original keys.

The new concept of 'standard actions' defines a set of engine actions
that are commonly available in the games supported by ScummVM. Backends
can define default bindings for the standard actions to hardware
specific input devices.
2020-01-29 08:51:29 +01:00
Bastien Bouclet
13fbdb935a KEYMAPPER: Use custom backend actions for the SDL graphics keymap 2020-01-29 08:51:29 +01:00
Bastien Bouclet
be49fc4b9a SDL: Add a keymap for the graphics manager 2020-01-29 08:51:29 +01:00
Bastien Bouclet
c131e8f5b9 EVENTS: Use the keymapper for some previously hard-coded key bindings 2020-01-29 08:51:29 +01:00
Bastien Bouclet
7617723ab5 KEYMAPPER: Allow backends to register multiple keymaps 2020-01-29 08:51:29 +01:00
Bastien Bouclet
ec9c394787 KEYMAPPER: Remove DefaultEventMapper
Now the keymapper is enabled by default, it does not make sense to have
a separate class anymore.
2020-01-29 08:51:29 +01:00
Bastien Bouclet
14663c4790 KEYMAPPER: Make the keymapper mandatory 2020-01-29 08:51:29 +01:00
Bastien Bouclet
cc336635a1 KEYMAPPER: Change custom backend action events not to be instant
Allows action consumers to choose if they want to react on the start or
on the end of an user interaction.
2020-01-29 08:51:29 +01:00
Bastien Bouclet
2d7588d9c3 EVENTS: Remove the dependency to EventSource from EventMapper 2020-01-29 08:51:29 +01:00
Filippos Karapetis
1b116170fa KEYMAPPER: Fix forward declarations of HardwareInput 2020-01-27 02:33:39 +02:00