mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-06 22:26:32 +02:00
* Revert to checking queryTrack()'s loved status.
This commit is contained in:
@@ -373,7 +373,7 @@ PlaylistItemDelegate::drawLoveBox( QPainter* painter, const QRect& rect, Playabl
|
|||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
TomahawkUtils::ImageType type = item->query()->track()->loved() ? TomahawkUtils::Loved : TomahawkUtils::NotLoved;
|
TomahawkUtils::ImageType type = item->query()->queryTrack()->loved() ? TomahawkUtils::Loved : TomahawkUtils::NotLoved;
|
||||||
QRect r = innerRect.adjusted( innerRect.width() - rect.height() + 4, 4, -4, -4 );
|
QRect r = innerRect.adjusted( innerRect.width() - rect.height() + 4, 4, -4, -4 );
|
||||||
painter->drawPixmap( r, TomahawkUtils::defaultPixmap( type, TomahawkUtils::Original, QSize( r.height(), r.height() ) ) );
|
painter->drawPixmap( r, TomahawkUtils::defaultPixmap( type, TomahawkUtils::Original, QSize( r.height(), r.height() ) ) );
|
||||||
m_loveButtonRects[ index ] = r;
|
m_loveButtonRects[ index ] = r;
|
||||||
@@ -462,7 +462,7 @@ PlaylistItemDelegate::editorEvent( QEvent* event, QAbstractItemModel* model, con
|
|||||||
|
|
||||||
if ( hoveringLove )
|
if ( hoveringLove )
|
||||||
{
|
{
|
||||||
item->query()->track()->setLoved( !item->query()->track()->loved() );
|
item->query()->queryTrack()->setLoved( !item->query()->queryTrack()->loved() );
|
||||||
}
|
}
|
||||||
else if ( hoveringInfo )
|
else if ( hoveringInfo )
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user