mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-01-17 06:18:17 +01:00
Add resolvers to diagnostics dialog
This commit is contained in:
parent
9b1b7be207
commit
4ba32e0add
@ -149,6 +149,15 @@ Pipeline::removeResolver( Resolver* r )
|
||||
}
|
||||
|
||||
|
||||
QList< Tomahawk::Resolver* >
|
||||
Pipeline::resolvers() const
|
||||
{
|
||||
Q_D( const Pipeline );
|
||||
|
||||
return d->resolvers;
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
Pipeline::addResolver( Resolver* r )
|
||||
{
|
||||
|
@ -66,6 +66,7 @@ public:
|
||||
QList< QPointer< ExternalResolver > > scriptResolvers() const;
|
||||
Tomahawk::ExternalResolver* resolverForPath( const QString& scriptPath );
|
||||
|
||||
QList< Resolver* > resolvers() const;
|
||||
void addResolver( Resolver* r );
|
||||
void removeResolver( Resolver* r );
|
||||
|
||||
|
@ -37,6 +37,7 @@
|
||||
#include "sip/SipPlugin.h"
|
||||
#include "utils/TomahawkUtilsGui.h"
|
||||
#include "utils/Logger.h"
|
||||
#include "Pipeline.h"
|
||||
|
||||
#include <QApplication>
|
||||
#include <QClipboard>
|
||||
@ -123,6 +124,20 @@ DiagnosticsDialog::updateLogView()
|
||||
log.append( accountLog( account ) + "\n" );
|
||||
}
|
||||
|
||||
|
||||
log.append( "RESOLVERS:\n" );
|
||||
|
||||
|
||||
connect( Tomahawk::Pipeline::instance(), SIGNAL( resolverAdded( Tomahawk::Resolver* ) ), SLOT( updateLogView() ), Qt::UniqueConnection );
|
||||
connect( Tomahawk::Pipeline::instance(), SIGNAL( resolverRemoved( Tomahawk::Resolver* ) ), SLOT( updateLogView() ), Qt::UniqueConnection );
|
||||
|
||||
const QList< Tomahawk::Resolver* > resolvers = Tomahawk::Pipeline::instance()->resolvers();
|
||||
foreach ( Tomahawk::Resolver* resolver, resolvers )
|
||||
{
|
||||
|
||||
log.append( resolver->name() + "\n" );
|
||||
}
|
||||
|
||||
ui->text->setText( log );
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user