mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-26 15:25:04 +02:00
* Giving domme a style-lesson ;-)
This commit is contained in:
@@ -24,18 +24,20 @@
|
|||||||
#include "sourcelist.h"
|
#include "sourcelist.h"
|
||||||
#include "utils/tomahawkutils.h"
|
#include "utils/tomahawkutils.h"
|
||||||
|
|
||||||
QtScriptResolverHelper::QtScriptResolverHelper( const QString& scriptPath, QObject* parent ): QObject(parent)
|
|
||||||
|
QtScriptResolverHelper::QtScriptResolverHelper( const QString& scriptPath, QObject* parent )
|
||||||
|
: QObject( parent )
|
||||||
{
|
{
|
||||||
m_scriptPath = scriptPath;
|
m_scriptPath = scriptPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
QString
|
QString
|
||||||
QtScriptResolverHelper::readFile( const QString& fileName )
|
QtScriptResolverHelper::readFile( const QString& fileName )
|
||||||
{
|
{
|
||||||
QString path = QFileInfo( m_scriptPath ).absolutePath();
|
QString path = QFileInfo( m_scriptPath ).absolutePath();
|
||||||
// remove directories
|
// remove directories
|
||||||
QString cleanedFileName = QFileInfo( fileName ).fileName();
|
QString cleanedFileName = QFileInfo( fileName ).fileName();
|
||||||
|
|
||||||
QString absoluteFilePath = path.append( "/" ).append( cleanedFileName );
|
QString absoluteFilePath = path.append( "/" ).append( cleanedFileName );
|
||||||
|
|
||||||
QFile file( absoluteFilePath );
|
QFile file( absoluteFilePath );
|
||||||
|
@@ -92,6 +92,7 @@ public:
|
|||||||
|
|
||||||
virtual QWidget* configUI() const { return 0; } // TODO support properly for qtscript resolvers too!
|
virtual QWidget* configUI() const { return 0; } // TODO support properly for qtscript resolvers too!
|
||||||
virtual void saveConfig() {}
|
virtual void saveConfig() {}
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
virtual void resolve( const Tomahawk::query_ptr& query );
|
virtual void resolve( const Tomahawk::query_ptr& query );
|
||||||
virtual void stop();
|
virtual void stop();
|
||||||
|
Reference in New Issue
Block a user