1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-11 00:24:12 +02:00

Move ScriptPlugin initialization to own factory method

This commit is contained in:
Dominik Schmidt
2014-12-09 00:20:27 +01:00
parent 2890190c82
commit fa832e3a36
2 changed files with 9 additions and 0 deletions

View File

@@ -84,6 +84,13 @@ ScriptAccount::registerScriptPlugin( const QString& type, const QString& objectI
m_objects.insert( objectId, object );
}
scriptPluginFactory( type, object );
}
void
ScriptAccount::scriptPluginFactory( const QString& type, ScriptObject* object )
{
if ( type == "linkGenerator" )
{
tLog() << "Got link generator plugin";

View File

@@ -47,6 +47,8 @@ public:
void reportScriptJobResult( const QVariantMap& result );
void registerScriptPlugin( const QString& type, const QString& objectId );
virtual void scriptPluginFactory( const QString& type, ScriptObject* object );
private slots:
void onJobDeleted( const QString& jobId );