1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-10-04 17:41:42 +02:00

show source icon in now-playing widget

This commit is contained in:
Kilian Lackhove
2012-09-12 12:54:19 +02:00
parent 12421a071b
commit 2d28902b2d
4 changed files with 46 additions and 0 deletions

View File

@@ -178,6 +178,7 @@ Result::toVariant() const
m.insert( "album", album()->name() );
m.insert( "track", track() );
m.insert( "source", friendlySource() );
m.insert( "sourceIcon", sourceIcon() );
m.insert( "mimetype", mimetype() );
m.insert( "size", size() );
m.insert( "bitrate", bitrate() );
@@ -294,6 +295,20 @@ Result::friendlySource() const
}
QPixmap
Result::sourceIcon() const
{
if ( collection().isNull() )
{
return m_sourceIcon;
}
else
{
return collection()->source()->avatar( Source::FancyStyle );
}
}
Tomahawk::Resolver*
Result::resolvedBy() const
{