mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-05 05:37:29 +02:00
* Cleaned up DropJobNotifier.
This commit is contained in:
@@ -32,10 +32,9 @@
|
|||||||
#include <QtNetwork/QNetworkAccessManager>
|
#include <QtNetwork/QNetworkAccessManager>
|
||||||
#include <QtNetwork/QNetworkReply>
|
#include <QtNetwork/QNetworkReply>
|
||||||
|
|
||||||
class QNetworkReply;
|
|
||||||
|
|
||||||
using namespace Tomahawk;
|
using namespace Tomahawk;
|
||||||
|
|
||||||
|
|
||||||
DropJobNotifier::DropJobNotifier( QPixmap servicePixmap, QString service, DropJob::DropType type, QNetworkReply* job )
|
DropJobNotifier::DropJobNotifier( QPixmap servicePixmap, QString service, DropJob::DropType type, QNetworkReply* job )
|
||||||
: JobStatusItem()
|
: JobStatusItem()
|
||||||
, m_type( "unknown" )
|
, m_type( "unknown" )
|
||||||
@@ -51,6 +50,7 @@ DropJobNotifier::DropJobNotifier( QPixmap servicePixmap, QString service, DropJo
|
|||||||
connect( job, SIGNAL( finished() ), this, SLOT( setFinished() ) );
|
connect( job, SIGNAL( finished() ), this, SLOT( setFinished() ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
DropJobNotifier::DropJobNotifier( QPixmap pixmap, DropJob::DropType type )
|
DropJobNotifier::DropJobNotifier( QPixmap pixmap, DropJob::DropType type )
|
||||||
: JobStatusItem()
|
: JobStatusItem()
|
||||||
, m_job( 0 )
|
, m_job( 0 )
|
||||||
@@ -61,23 +61,24 @@ DropJobNotifier::DropJobNotifier( QPixmap pixmap, DropJob::DropType type )
|
|||||||
|
|
||||||
|
|
||||||
DropJobNotifier::~DropJobNotifier()
|
DropJobNotifier::~DropJobNotifier()
|
||||||
{}
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
DropJobNotifier::init( DropJob::DropType type )
|
DropJobNotifier::init( DropJob::DropType type )
|
||||||
{
|
{
|
||||||
if ( type == DropJob::Playlist )
|
if ( type == DropJob::Playlist )
|
||||||
m_type = "playlist";
|
m_type = tr( "playlist" );
|
||||||
|
|
||||||
if ( type == DropJob::Artist )
|
if ( type == DropJob::Artist )
|
||||||
m_type = "artist";
|
m_type = tr( "artist" );
|
||||||
|
|
||||||
if ( type == DropJob::Track )
|
if ( type == DropJob::Track )
|
||||||
m_type = "track";
|
m_type = tr( "track" );
|
||||||
|
|
||||||
if ( type == DropJob::Album )
|
if ( type == DropJob::Album )
|
||||||
m_type = "album";
|
m_type = tr( "album" );
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -87,6 +88,7 @@ DropJobNotifier::rightColumnText() const
|
|||||||
return QString();
|
return QString();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
QPixmap
|
QPixmap
|
||||||
DropJobNotifier::icon() const
|
DropJobNotifier::icon() const
|
||||||
{
|
{
|
||||||
@@ -108,6 +110,7 @@ DropJobNotifier::mainText() const
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
DropJobNotifier::setFinished()
|
DropJobNotifier::setFinished()
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user