1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-16 02:54:33 +02:00

added the avatar frame also to the Collection and SuperCollection icons

BUG: TWK-337
This commit is contained in:
Michael Zanetti
2011-08-10 17:19:00 +02:00
parent d3ab32d06a
commit bc3662a997
2 changed files with 6 additions and 5 deletions

View File

@@ -30,7 +30,6 @@
#include <QCoreApplication>
#include "utils/logger.h"
#include "utils/tomahawkutils.h"
using namespace Tomahawk;
@@ -130,7 +129,7 @@ QPixmap
Source::avatar() const
{
if( !m_avatar.isNull() )
return TomahawkUtils::createAvatarFrame( m_avatar );
return m_avatar;
else
return QPixmap();
}

View File

@@ -159,15 +159,17 @@ CollectionItem::activate()
QIcon
CollectionItem::icon() const
{
QPixmap pixmap;
if( m_source.isNull() )
return QIcon( RESPATH "images/supercollection.png" );
pixmap = QPixmap( RESPATH "images/supercollection.png" );
else
{
if( m_source->avatar().isNull() )
return QIcon( RESPATH "images/user-avatar.png" );
pixmap = QPixmap( RESPATH "images/user-avatar.png" );
else
return QIcon( m_source->avatar() );
pixmap = m_source->avatar();
}
return QIcon( TomahawkUtils::createAvatarFrame( pixmap ) );
}