Commit Graph

439 Commits

Author SHA1 Message Date
Cameron Cawley
f88769f132 BASE: Fix a crash when attempting to run a disabled engine 2021-04-08 12:18:11 +03:00
Cameron Cawley
3e8ab22eb2 BASE: Don't attempt to unload detection code when building with static detection 2021-04-07 14:38:51 +02:00
Cameron Cawley
a1890ede9c BASE: Avoid calling PluginMan.getEngineFromMetaEngine where possible 2021-04-05 15:33:23 +01:00
Thierry Crozat
67720ef658 JANITORIAL: Remove obselete references to MetaEngineConnect
At some point when splitting the MetaEngine to a detection
plugin and a static meta engine, the former was called
MetaEngine while the latter was called MetaEngineConnect.
Thus was then later change to MetaEngineDetection and
MetaEngine. But some references were left to the former
names in comments and documentation.
2021-02-14 14:32:36 +00:00
av-dx
7950a9b215 GUI: Refresh stretch mode and shader on returning to launcher 2021-01-24 04:09:09 +02:00
Thierry Crozat
a1c807704d ALL: Ignore force RTL option when the engine does not support RTL
This fixes bug #12072: Cannot quit Blazing Dragons when always
return to launcher is selected
2021-01-20 23:35:47 +00:00
Vladimir Serbinenko
0d39e96f55 COMMON: Make TranslationManager reusable.
This makes it possible to reuse TranslationManager with different
files.
2020-12-17 09:49:18 +01:00
Thierry Crozat
4518f73f92 BASE: Remove FORCE_RETURN_TO_LAUNCHER define
This was only used by the ps2 backend, and that backend no longer
exists. Also now backends that want to force RTL should use the
kFeatureNoQuit OSystem feature instead.
2020-12-09 22:13:22 +00:00
Thierry Crozat
9e5540f838 BASE: Handle RTL at exit config in scummvm_main
This config was handled in the DefaultEventManager, but this did not
work for engines that quit the game without using a QUIT_EVENT (such
as SCI). So now it is handled one level up directly in scummvm_main.

Note: It is still also handled in the DefaultEventManager so that we
get the correct confirmation dialog there when "confirm_exit" is true.
2020-12-09 22:13:22 +00:00
Cameron Cawley
01b4432825 BACKENDS: Use Common::U32String for OSystem::setWindowCaption 2020-11-22 17:20:19 +00:00
Cameron Cawley
11724f9df1 GUI: Add a tab for backend-specific options 2020-11-22 16:35:03 +00:00
Eugene Sandulenko
7ff34bc9ec PLUGINS: MetaEngineStatic -> MetaEngineDetection 2020-10-11 23:14:39 +02:00
Eugene Sandulenko
7ea6781043 PLUGINS: PLUGIN_TYPE_METAENGINE -> PLUGIN_TYPE_ENGINE_DETECTION 2020-10-11 23:12:32 +02:00
aryanrawlani28
41af1b63a9 BASE: PLUGINS: Improve fb detection for Sci & Wintermute 2020-10-03 14:56:36 +02:00
aryanrawlani28
71a820caff ENGINES: Begin class renaming of ME & AME
- ME -> MetaEngineStatic (static parts)
- MEC -> MetaEngine (dynamic parts)
2020-10-03 14:56:36 +02:00
aryanrawlani28
c48719404a BASE: PLUGINS: Rename plugin matching helpers
- give*From* -> get*From*
2020-10-03 14:56:36 +02:00
aryanrawlani28
5f5363f03b BASE: MAIN: Load/Unload detection plugin for UncachedPluginMan as/when needed.
- Used only in context of UncachedPluginMan
- Always load on startup
- When starting a game, unload all other MetaEngines except the one needed.
2020-10-03 14:56:36 +02:00
aryanrawlani28
0cc8719417 BASE: ENGINES: Adapt to keymaps moving to engine plugins
- Also improvise usage of MetaEngineConnect in main.cpp a bit.
2020-10-03 14:56:36 +02:00
aryanrawlani28
9353e339c6 BASE: MAIN: Proper usage of unloadPluginsExcept before running a game. 2020-10-03 14:56:36 +02:00
aryanrawlani28
575e77522a BASE: MAIN: Change how running games works.
- In runGame(), in main.cpp, we get a plugin of type MetaEngine.
- This MetaEngine cannot createInstances, but it just a helper class.
- Connect a MetaEngine class with it's factory class - MetaEngineConnect.
- Then, simply call the method.
2020-10-03 14:56:36 +02:00
aryanrawlani28
4b6976c558 GUI: U32: Reduce number of files changed and fixes
Up until last commit, everything was working fine but the amount of files changed was too large. This commit tries to reduce the changes.

- Add a fake constructor to Keymap, text-to-speech, setDescription (save-state)
- Redirecting functions for PopUpWidget::appendEntry, ButtonWidget::setLabel, GUIErrorMessage
- Use the above functions and constructors to reduce changes in Engines
- Fix warnings being in unicode. Only output english text in - Warnings, Errors, etc.
- Mark some strings as "translation" strings. (Not yet added to POTFILES)
- Remove some CP related things from po/modules.mk
- Previously used some Common::convertToU32 where it was not necessary, replace this with u32constructor
2020-08-30 14:43:41 +02:00
aryanrawlani28
f800ca4ada GUI: U32: Convert majority of code to use U32
This commit also includes some additional major changes.

- Return U32String from TransMan getTranslation()
- Change tooltips to be U32Strings
- Remove temporary code of convertToU32String
- U32 Support various dialogs (Browser, FileBrowser, Messages, Chooser, etc)
- U32 for music plugins
- U32 for OSD messages
- Add some helper functions to ustr.cpp
- Change default tooltips from nullptr & 0 -> ""
- Some runtime exceptions may occur when changing languages due to incorrect String::Format
2020-08-30 14:43:41 +02:00
Cameron Cawley
cc5abf5ebb TTS: Fix crash when TextToSpeechManager is unavailable, clean up formatting 2020-05-27 12:43:49 +02:00
mataniko
2f5eb14d4b JANITORIAL: Rename additional RTL references and comments 2020-05-12 10:36:38 +02:00
mataniko
321a02aff2 JANITORIAL: Rename shouldRTL, resetRTL and FORCE_RTL 2020-05-12 10:36:38 +02:00
Bastien Bouclet
bcfb7145fa GUI: Allow engines to define a fully custom tab in the edit game dialog
By implementing MetaEngine::buildEngineOptionsWidget, engines can
instantiate a container widget that will be shown in the Engine tab of
the edit game dialog. The default implementation retains the existing
behavior and shows the extra GUI options.
2020-03-28 07:38:39 +01:00
Bastien Bouclet
9cc2fee887 SDL: Enable joystick input by default
Game controller input is now enabled whenever a compatible device is
connected. The keymapper's keymaps are refreshed when a joystick is added
or removed.

Fixes #10366.
2020-03-16 18:41:27 +01:00
Cameron Cawley
f2db412ba5 GUI: Store the shader name in the config file instead of the ID 2020-03-09 18:01:14 -05:00
Cameron Cawley
7488e17c0a GUI: Allow shaders to be selected for individual targets 2020-03-09 18:01:14 -05:00
Zvika Haramaty
3b4810aab4 AUDIO: Added dump-midi mechanism
This mechanism is enabled by '--dump-midi' command line parameter.
The midi events are printed to screen, and dumped to 'dump.mid' file.
2020-02-28 08:27:12 +02: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
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
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
7617723ab5 KEYMAPPER: Allow backends to register multiple keymaps 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
8dd2b7ca39 EVENTS: Expose the primary global keymap builder 2020-01-26 23:09:08 +02:00
Bastien Bouclet
be388fd9b0 BASE: Don't needlessly go through EngineMan to get the game description 2020-01-26 23:09:08 +02:00
Bastien Bouclet
ee8229dc00 ENGINES: Move keymap initialization to MetaEngine
To be able to access the keymap while the engine is not running.
2020-01-26 23:09:08 +02:00
Bastien Bouclet
19de568e24 KEYMAPPER: Untangle the dependencies between Action and Keymap 2020-01-26 23:09:08 +02:00
Bastien Bouclet
576982bc33 KEYMAPPER: Use the default action bindings defined by the backends 2020-01-26 19:07:53 +01:00
Bastien Bouclet
17791e2f7d KEYMAPPER: Actions can now have default mappings 2020-01-26 19:07:53 +01:00
Bastien Bouclet
9c0bc2b633 KEYMAPPER: Simplify the way keymaps are enabled and disabled 2020-01-26 19:07:53 +01:00
Bastien Bouclet
ac44469558 KEYMAPPER: Remove the domain class 2020-01-26 19:07:53 +01:00
Bastien Bouclet
e197a75829 KEYMAPPER: Action can generate only a single event 2020-01-26 19:07:53 +01:00
Bastien Bouclet
b7a816f1eb KEYMAPPER: Clean up the classes dependencies 2020-01-26 19:07:53 +01:00
Cameron Cawley
795452042e BASE: Add mouse click events to the global keymap 2020-01-21 19:49:10 +00:00
Bastien Bouclet
9454346782 ENGINES: Copy the data referenced by QualifiedGameDescriptor
The engineId, gameId and description come from static data in the game
engines. When the game engines are compiled as dynamic plugins, the QGD
structure may outlive the engine plugin. Making a copy ensures the data
remains available.

Fixes #11292.
2020-01-01 08:19:48 +01:00
Cameron Cawley
f2b9f7bb76 BACKENDS: Remove the Windows CE port 2019-11-17 22:33:56 +01:00
Bastien Bouclet
c142838122 BASE: Change the command line interface to use engine-qualified game names
Qualified game names have the following form: engineId:gameId.
Unqualified game names are still supported as long as they are not
ambiguous. However they are considered deprecated and are no longer
displayed by the --list-games command.
2019-11-03 11:43:00 +01:00
Bastien Bouclet
ae9f764c7a ENGINES: Automatically upgrade the targets on launch to add an engine ID 2019-11-03 11:43:00 +01:00