mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-07-31 11:20:22 +02:00
darker background for highlight on osx
This commit is contained in:
@@ -160,7 +160,11 @@ AlbumItemDelegate::paint( QPainter* painter, const QStyleOptionViewItem& option,
|
|||||||
if ( m_hoveringOver == index )
|
if ( m_hoveringOver == index )
|
||||||
TomahawkUtils::drawQueryBackground( painter, opt.palette, r, 1.5 );
|
TomahawkUtils::drawQueryBackground( painter, opt.palette, r, 1.5 );
|
||||||
|
|
||||||
|
#ifdef Q_WS_MAC
|
||||||
|
painter->setPen( opt.palette.color( QPalette::Dark ).darker( 200 ) );
|
||||||
|
#else
|
||||||
painter->setPen( opt.palette.color( QPalette::Dark ) );
|
painter->setPen( opt.palette.color( QPalette::Dark ) );
|
||||||
|
#endif
|
||||||
to.setAlignment( Qt::AlignHCenter | Qt::AlignBottom );
|
to.setAlignment( Qt::AlignHCenter | Qt::AlignBottom );
|
||||||
text = painter->fontMetrics().elidedText( item->album()->artist()->name(), Qt::ElideRight, textRect.width() - 3 );
|
text = painter->fontMetrics().elidedText( item->album()->artist()->name(), Qt::ElideRight, textRect.width() - 3 );
|
||||||
painter->drawText( textRect, text, to );
|
painter->drawText( textRect, text, to );
|
||||||
|
Reference in New Issue
Block a user