From 1ae065382c31fc25e213eab230ef03b7df362226 Mon Sep 17 00:00:00 2001 From: Ben Boeckel Date: Sat, 6 Jun 2009 16:33:26 -0400 Subject: Add extensionto PluginLoader --- sigtools/PluginLoader.cpp | 8 ++++++++ sigtools/PluginLoader.h | 1 + 2 files changed, 9 insertions(+) (limited to 'sigtools') diff --git a/sigtools/PluginLoader.cpp b/sigtools/PluginLoader.cpp index 8de9e16e..2603c169 100644 --- a/sigtools/PluginLoader.cpp +++ b/sigtools/PluginLoader.cpp @@ -72,6 +72,14 @@ QIcon PluginLoader::icon(const QString& type, const QString& name) return QIcon(); } +QStringList PluginLoader::extensions(const QString& type, const QString& name) +{ + PluginBase* plugin = loader->factory(type, name); + if (plugin) + return plugin->extensions(name); + return QStringList(); +} + QSharedPointer PluginLoader::game(const QString& game) { return loader->game(game); diff --git a/sigtools/PluginLoader.h b/sigtools/PluginLoader.h index 6136e806..ce8b6dc7 100644 --- a/sigtools/PluginLoader.h +++ b/sigtools/PluginLoader.h @@ -54,6 +54,7 @@ namespace PluginLoader SIGTOOLS_EXPORT QString description(const QString& type, const QString& name); SIGTOOLS_EXPORT QIcon icon(const QString& type, const QString& name); + SIGTOOLS_EXPORT QStringList extensions(const QString& type, const QString& name); SIGTOOLS_EXPORT QSharedPointer game(const QString& game); SIGTOOLS_EXPORT Sigencore::Arena* arena(const QString& arena, Sigscript::GameWrapper* game, Sigscript::Config* parent); -- cgit