Added plugin priority so there's just one plugin that provides a module functionality.

svn-id: r32121
This commit is contained in:
Jordi Vilalta Prat 2008-05-14 17:26:05 +00:00
parent c834bbba06
commit b35941c3c2
2 changed files with 22 additions and 13 deletions

View file

@ -27,9 +27,8 @@
#define BASE_PLUGINS_H
#include "common/error.h"
#include "common/list.h"
#include "common/singleton.h"
#include "base/game.h"
#include "common/util.h"
#ifdef DYNAMIC_MODULES
#include "common/fs.h"
@ -69,7 +68,7 @@ enum PluginType {
};
// TODO: Make the engine API version depend on ScummVM's version
// because of the backlinking
// because of the backlinking (posibly from the SVN revision)
#define PLUGIN_TYPE_ENGINE_VERSION 1
#define PLUGIN_TYPE_MIDI_VERSION 1
@ -274,7 +273,7 @@ protected:
* managing all Plugin class instances, and unloading them.
*/
class PluginManager : public Common::Singleton<PluginManager> {
typedef Common::List<PluginProvider *> ProviderList;
typedef Common::Array<PluginProvider *> ProviderList;
private:
PluginList _plugins[PLUGIN_TYPE_MAX];
ProviderList _providers;