Commit Graph

217 Commits

Author SHA1 Message Date
Bastien Bouclet c5b92bcb2e GUI: Better integration for the unknown game dialog when adding games
* The list of candidates now includes unknown variants. When an unknown
variant is selected, the unknown game dialog is shown.
* On the unknown game dialog, users are given the choice to add the game
when that is possible, or to cancel.

The goal of those changes is to make the unknown game dialog less
confusing for users, especially when both known and unknown games
variants are found.
2019-05-12 11:44:51 +03:00
Eric Culp 6d11f46b15 BASE: Only reload engine plugins after return to launcher
The other plugins do not need to be reloaded. Reloading
the scaler plugins breaks the graphics.
2019-03-10 03:49:29 +02:00
Paul Gilbert ef161922d8 ENGINES: Add optional extra configuration entries when creating new targets 2018-12-08 19:05:59 -08:00
Bastien Bouclet 9d62f13e3a BASE: Fix a segfault when mass detector encounters an empty directory
Was introduced in the recent detection rework.
2018-06-17 18:09:40 +02:00
Bastien Bouclet 1dcb8076db ENGINES: Remove usage of C++11 extended initializer lists 2018-05-10 09:26:26 +02:00
Bastien Bouclet 90b78c5446 ENGINES: Merge GameDescriptor and DetectedGame 2018-05-10 09:04:23 +02:00
Bastien Bouclet faa2534f46 ENGINES: Factor adding games to ConfMan 2018-05-10 09:04:23 +02:00
Bastien Bouclet 5aff87dc15 ENGINES: Turn GameDescriptor into a simple struct 2018-05-10 09:04:23 +02:00
Bastien Bouclet 8fb149e3c7 ENGINES: Change MetaEngine::findGame to return a plain game descriptor 2018-05-10 09:04:23 +02:00
Bastien Bouclet cf1ebf2951 ENGINES: Add unknown game variants to the game detector results 2018-05-10 09:04:23 +02:00
Lothar Serra Mari 451cf2304f ENGINES: Show the unknown Game dialog only when the detector is launched by the Add Game feature 2018-04-29 21:47:10 +01:00
Adrian Frühwirth 3747d852ee JANITORIAL: Fix whitespace 2018-04-15 16:31:31 +02:00
Colin Snover d087c9605f BASE: Remove bad casts between incompatible Plugin types
Previously, a C-style cast was used to convert a
Common::Array<Plugin *>, populated with pointers to StaticPlugin
and DynamicPlugin instances, to a
Common::Array<PluginSubclass<T> *>, but PluginSubclass<T> is a
*sibling* class to StaticPlugin/DynamicPlugin, so this cast was
invalid and the results undefined. The methods for retrieving
subclasses of plugins can't be easily changed to just generate an
array of temporary wrapper objects that expose an identical API
which dereferences to the preferred PluginObject subclass because
pointers to these objects are retained by other parts of ScummVM,
so the wrappers would needed to be persisted or they would need to
just re-expose the underlying Plugin object again. This indicated
that a way to solve this problem is to have the callers receive
Plugin objects and get the PluginObject from the Plugin by
explicitly stating their desired type, in a similar manner to
std::get(std::variant), so that the pattern used by this patch to
solve the problem.

Closes gh-1051.
2017-12-03 20:26:38 -06:00
Eugene Sandulenko 940b2a20f1 Revert "COMMON: Change way the Singleton instances are instantiated"
This reverts commit eefa72afa1.

With this patch ConfigManager is broken.
2017-07-10 21:17:41 +02:00
Thierry Crozat eefa72afa1 COMMON: Change way the Singleton instances are instantiated
This fixes tons of warnings with clang from a recent xcode version on
macOS (and possibly other systems) complaining that an instantiation
of _singleton is required but no definition is available.
2017-07-10 21:11:20 +02:00
Johannes Schickel f62153c795 BASE: Make GPL headers consistent in themselves. 2014-02-18 02:39:32 +01:00
Johannes Schickel c70f7cb1a7 BASE: Small formatting fix. 2014-01-25 19:34:03 +01:00
Jonathan Gray 8cfe25cd65 MIDI: add sndio midi backend
New sndio MIDI backend for OpenBSD written by Alexandre Ratchov.
Tested with an external MT-32 and fluidsynth.
2012-05-15 16:39:21 +10:00
Max Horn 5185c61a2e ENGINES: Move table of engines from base/plugins.cpp to new header
The new header engines/plugins_table.h is currently manually created
and maintained, but could be regenerated by a script in the future.
2012-04-18 15:44:11 +02:00
Johannes Schickel 1adc7f0bdd BASE: Remove unneeded code in PluginManagerUncached.
Thanks to Yotam for confirming that this isn't needed anymore.
2012-02-10 01:45:16 +01:00
Alex Bevilacqua 4c60382604 TOLTECS: integrate engine 2011-11-20 22:43:12 +01:00
Paul Gilbert b0611f3189 M4: Removed the M4/MADS engine from trunk 2011-11-20 12:14:10 +11:00
Alyssa Milburn 84063dc972 Merge remote-tracking branch 'origin/master' into soltys_wip2 2011-08-22 20:03:05 +02:00
Sven Hesse 4da83afa5a BASE: Fix indentation 2011-08-22 09:48:42 +02:00
Chris Warren-Smith 8a2243ff36 BADA: Remove BADA defined check. Was a temp fix for simulator build 2011-08-21 16:39:08 +10:00
Chris Warren-Smith 59739a7a0e BADA: Initial BADA port implementation 2011-08-21 16:37:06 +10:00
Alyssa Milburn 40a6c232e9 COMPOSER: Add a first attempt at an engine. 2011-07-14 20:08:06 +02:00
Alyssa Milburn 66e81d633f Merge remote-tracking branch 'origin/master' into soltys_wip2 2011-07-07 09:24:10 +02:00
Ori Avtalion aa0f307e06 ALL: Require DECLARE_SINGLETON to be used in the Common namepsace
Silences the clang warning:

  static data member specialization of '_singleton' must
  originally be declared in namespace 'Common'; accepted as a C++0x
  extension [-Wc++0x-extensions]

Wrapping "namespace Common {}" around the macro assignment causes clang
to complain about a spurious semicolon, and removing the semicolon at
the end of the macro causes some editors to misbehave.

Changing the requirement of using the macro in one namespace (the
global) to another (Common) seems a small price to pay to
silence a warning.
2011-06-30 22:41:41 +03:00
Strangerke b0c9c9122f Merge branch 'master' of github.com:scummvm/scummvm into soltys_wip2 2011-06-29 16:15:41 +02:00
Max Horn 88913c0139 ALL: Remove trailing whitespaces
This tries to make our code a bit more compliant with our code formatting
conventions. For future use, this is the command I used:
  git ls-files "*.cpp" "*.h" | xargs sed -i -e 's/[ \t]*$//'
2011-06-20 00:59:48 +02:00
Vladimir 52a89174ab DREAMWEB: added autogenerated source 2011-06-15 17:29:05 +02:00
Strangerke c545ebd0d5 CGE: Add minimal engine and detection 2011-09-10 17:50:47 +02:00
athrxx 5c34e33c2c FM-TOWNS AUDIO: Some more midi driver code for FM-TOWNS monkey2 and indy4 2011-05-17 20:24:24 +02:00
strangerke 69b1485a22 GIT: Clean up: Suppress SVN tags, now useless 2011-05-12 01:16:22 +02:00
Paul Gilbert e6090415b6 Merge remote branch 'remotes/dreammaster/tsage' 2011-04-13 21:08:05 +10:00
dhewg 0e6cdfd675 ANDROID: Experimental MIDI Driver
Based on the SONiVOX® Embedded Audio Synthesis (EAS™) library, which is
part of the base Android OS.

CPU stats (Cortex A8 1GHz, monkey1 intro, peak values):
MAME OPL: 30%
DosBox OPL: 26%
EAS: 19%
2011-03-25 14:43:52 +01:00
Paul Gilbert 7042d95cfe TSAGE: Added the engine in a separate branch 2011-02-14 20:37:27 +11:00
Max Horn 42ab839dd6 AUDIO: Rename sound/ dir to audio/
svn-id: r55850
2011-02-09 01:09:01 +00:00
Yotam Barnoy c4095aabc5 PLUGINS: for uncached plugins, first check the loaded plugin before looking elsewhere
There are some calls to EngineManager::findGame() from within games, such as when loading saved games. It's critical not to unload the plugin from memory or other threads may crash. Therefore, we first scan using any plugin that's already in memory.

svn-id: r55089
2011-01-02 10:08:02 +00:00
Yotam Barnoy 7558331550 PLUGINS: rename ONE_PLUGIN_AT_A_TIME define to UNCACHED_PLUGINS
ONE_PLUGIN_AT_A_TIME is too long.

svn-id: r55064
2010-12-30 08:01:58 +00:00
Florian Kagerer 5e88223e8e PLUGINS: fixed MSVC build
svn-id: r55062
2010-12-29 15:37:57 +00:00
Yotam Barnoy 8f36a5f887 PLUGINS: single plugin model now saves plugin filename to config file
After searching for the right plugin once, the filename will be saved to the config file under the domain 'plugin_files'. The key is the gameid and the value is the plugin file. The backup mechanism is searching plugin by plugin.

svn-id: r55061
2010-12-29 15:25:21 +00:00
Yotam Barnoy ee2b1092ab PLUGINS: switched plugin manager to inheritance rather than #defines
The reason for this was that I found issues where the wrong functions were called in EngineManager for single plugin operation. Rather than inserting more messy #defines, I preferred to change the PluginManager to use virtual functions, which also makes EngineManager simpler.

svn-id: r55024
2010-12-23 13:38:37 +00:00
Yotam Barnoy 81dd62f3cb PLUGINS: don't fully load each plugins at startup for single plugin method
The reason to load each plugin was to figure out if it's a sound or engine plugin. Since all our plugin files are currently engines, there's no reason to load every file. If we get dynamic sound plugins, it'd be a good idea to make a quick and easy way to know which kind of plugin it is (e.g. a prefix or suffix in the filename).

svn-id: r55021
2010-12-23 07:54:54 +00:00
Max Horn abe1959d36 COMMON: Simplify DECLARE_SINGLETON macro
This makes it possible to write
  DECLARE_SINGLETON(foo);
instead of
  DECLARE_SINGLETON(foo)
without causing a warning about an extra semicolon.
The extra semicolon helps some editors at parsing the C++ code.

svn-id: r54258
2010-11-16 08:23:13 +00:00
Yotam Barnoy a6bee87990 PLUGINS: improved one-at-a-time plugin code
I reduced memory fragmentation using 2 principles: Plugins should be loaded for as little time as possible, and long lasting memory allocations should be allocated before plugins are loaded. There might still be a little fragmentation left.
Note that command line settings that require plugins to be loaded don't work yet, but they didn't work (properly) before either.

svn-id: r54097
2010-11-05 13:24:57 +00:00
Yotam Barnoy 94c8d0a14d Updated with latest from trunk
svn-id: r53976
2010-10-31 11:08:43 +00:00
Eugene Sandulenko 937cf6cd7a CONFIGURE: Plug in Last Express engine
svn-id: r53580
2010-10-18 19:18:06 +00:00
Johannes Schickel 3b81a9489e SOUND: Allow TiMidity support to be disabled via configure.
svn-id: r53395
2010-10-13 00:48:40 +00:00