mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-04 21:27:58 +02:00
Don't paint selected text as white on osx, there's no selection rect.
This commit is contained in:
@@ -61,11 +61,12 @@ AlbumItemDelegate::paint( QPainter* painter, const QStyleOptionViewItem& option,
|
|||||||
initStyleOption( &opt, QModelIndex() );
|
initStyleOption( &opt, QModelIndex() );
|
||||||
qApp->style()->drawControl( QStyle::CE_ItemViewItem, &opt, painter );
|
qApp->style()->drawControl( QStyle::CE_ItemViewItem, &opt, painter );
|
||||||
|
|
||||||
|
#ifndef Q_OS_MAC
|
||||||
if ( option.state & QStyle::State_Selected )
|
if ( option.state & QStyle::State_Selected )
|
||||||
{
|
{
|
||||||
opt.palette.setColor( QPalette::Text, opt.palette.color( QPalette::HighlightedText ) );
|
opt.palette.setColor( QPalette::Text, opt.palette.color( QPalette::HighlightedText ) );
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
painter->save();
|
painter->save();
|
||||||
|
|
||||||
// painter->setRenderHint( QPainter::Antialiasing );
|
// painter->setRenderHint( QPainter::Antialiasing );
|
||||||
|
Reference in New Issue
Block a user