1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-13 09:34:53 +02:00

* Tint default FlexibleTreeView's pixmap.

This commit is contained in:
Christian Muehlhaeuser
2014-09-02 05:57:30 +02:00
parent 660c0120ca
commit 2e6e96fdcc
2 changed files with 5 additions and 4 deletions

View File

@@ -55,6 +55,7 @@ FlexibleTreeView::FlexibleTreeView( QWidget* parent, QWidget* extraHeader )
m_header->setBackgroundColor( Qt::black );
m_header->setBackground( ImageRegistry::instance()->pixmap( RESPATH "images/collection_background_small.png", QSize( 0, 0 ) ), false );
setPixmap( TomahawkUtils::defaultPixmap( TomahawkUtils::DefaultCollection, TomahawkUtils::Original, QSize( 256, 256 ) ) );
// m_trackView->setPlaylistInterface( m_playlistInterface );
// m_columnView->setPlaylistInterface( m_trackView->proxyModel()->playlistInterface() );
@@ -369,17 +370,17 @@ FlexibleTreeView::setEmptyTip( const QString& tip )
void
FlexibleTreeView::setPixmap( const QPixmap& pixmap )
FlexibleTreeView::setPixmap( const QPixmap& pixmap, bool tinted )
{
m_pixmap = pixmap;
m_header->setPixmap( pixmap );
m_header->setPixmap( pixmap, tinted );
}
void
FlexibleTreeView::onModelChanged()
{
setPixmap( m_model->icon() );
setPixmap( m_model->icon(), false );
m_header->setCaption( m_model->title() );
m_header->setDescription( m_model->description() );

View File

@@ -70,7 +70,7 @@ public:
void setFlatModel( PlayableModel* model );
void setAlbumModel( PlayableModel* model );
void setPixmap( const QPixmap& pixmap );
void setPixmap( const QPixmap& pixmap, bool tinted = true );
void setEmptyTip( const QString& tip );
public slots: