mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-04 21:27:58 +02:00
Don't show speaker next to a playlist if not paused or playing
This commit is contained in:
@@ -144,8 +144,8 @@ SourceDelegate::paint( QPainter* painter, const QStyleOptionViewItem& option, co
|
|||||||
type == SourcesModel::Station ||
|
type == SourcesModel::Station ||
|
||||||
type == SourcesModel::TemporaryPage ||
|
type == SourcesModel::TemporaryPage ||
|
||||||
type == SourcesModel::GenericPage );
|
type == SourcesModel::GenericPage );
|
||||||
|
const bool playing = ( AudioEngine::instance()->isPlaying() || AudioEngine::instance()->isPaused() );
|
||||||
if ( playable && item->isBeingPlayed() )
|
if ( playable && playing && item->isBeingPlayed() )
|
||||||
{
|
{
|
||||||
const int iconW = o3.rect.height() - 4;
|
const int iconW = o3.rect.height() - 4;
|
||||||
QRect iconRect = QRect( option.rect.x() - iconW - 4, option.rect.y() + 2, iconW, iconW );
|
QRect iconRect = QRect( option.rect.x() - iconW - 4, option.rect.y() + 2, iconW, iconW );
|
||||||
|
Reference in New Issue
Block a user