1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-03-20 07:49:42 +01:00

* Fixed ArtistAndAlbum hover states.

This commit is contained in:
Christian Muehlhaeuser 2012-12-08 21:39:43 +01:00
parent 19d91d7cba
commit f1ae9ce222

@ -372,8 +372,8 @@ QueryLabel::paintEvent( QPaintEvent* event )
QPainter p( this );
QRect r = contentsRect();
QString s = text();
const QString elidedText = fontMetrics().elidedText( s, m_mode, r.width() );
const QFontMetrics& fm = fontMetrics();
const QString elidedText = fm.elidedText( s, m_mode, r.width() );
p.save();
p.setRenderHint( QPainter::Antialiasing );
@ -624,8 +624,8 @@ QueryLabel::mouseMoveEvent( QMouseEvent* event )
{
m_hoverType = Album;
int spacing = ( m_type & Artist ) ? dashX : 0;
hoverArea.setLeft( artistX + spacing );
hoverArea.setRight( albumX + spacing + contentsMargins().left() - 1 );
hoverArea.setLeft( artistX + spacing - contentsMargins().left() );
hoverArea.setRight( albumX + contentsMargins().left() - 1 );
}
else if ( m_type & Track && x < trackX && x > albumX )
{