1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-07 14:46:33 +02:00

Unnecessary hack is unnecessary.

This commit is contained in:
Teo Mrnjavac
2014-01-02 17:12:52 +01:00
parent 7b854ee009
commit b4ad00fe2c
3 changed files with 1 additions and 14 deletions

View File

@@ -455,16 +455,6 @@ ColumnView::guid() const
} }
void
ColumnView::onScrollBarChanged( int value )
{
QWidget* parent = qobject_cast< QWidget* >( m_previewWidget->parent() );
parent->scroll( 0, m_scrollDelta - value );
m_scrollDelta = value;
}
void void
ColumnView::fixScrollBars() ColumnView::fixScrollBars()
{ {
@@ -486,8 +476,6 @@ ColumnView::fixScrollBars()
if ( sb && sb->orientation() == Qt::Vertical ) if ( sb && sb->orientation() == Qt::Vertical )
{ {
sb->setSingleStep( 6 ); sb->setSingleStep( 6 );
//FIXME: The preview widget should probably never scroll. Do we even need the following hack?
//connect( sb, SIGNAL( valueChanged( int ) ), SLOT( onScrollBarChanged( int ) ), Qt::UniqueConnection );
break; break;
} }

View File

@@ -97,8 +97,6 @@ private slots:
void onCustomContextMenu( const QPoint& pos ); void onCustomContextMenu( const QPoint& pos );
void onMenuTriggered( int action ); void onMenuTriggered( int action );
void onScrollBarChanged( int value );
private: private:
void fixScrollBars(); void fixScrollBars();

View File

@@ -191,6 +191,7 @@ ColumnViewPreviewWidget::setQuery( const Tomahawk::query_ptr& query )
m_trackLabel->setText( query->track()->track() ); m_trackLabel->setText( query->track()->track() );
m_artistLabel->setArtist( query->track()->artistPtr() ); m_artistLabel->setArtist( query->track()->artistPtr() );
m_artistLabel->setElideMode( Qt::ElideRight );
m_composerValue->setText( query->track()->composer() ); m_composerValue->setText( query->track()->composer() );
m_composerValue->setVisible( !query->track()->composerPtr().isNull() ); m_composerValue->setVisible( !query->track()->composerPtr().isNull() );