mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-03-25 02:09:48 +01:00
Merge branch 'stable'
This commit is contained in:
commit
d43db27ce0
@ -585,6 +585,8 @@ LastFmPlugin::topTracksReturned()
|
||||
QNetworkReply* reply = qobject_cast<QNetworkReply*>( sender() );
|
||||
|
||||
QStringList topTracks = lastfm::Artist::getTopTracks( reply );
|
||||
topTracks.removeDuplicates();
|
||||
|
||||
QVariantMap returnedData;
|
||||
returnedData["tracks"] = topTracks;
|
||||
|
||||
|
@ -38,6 +38,8 @@ RelatedArtistsContext::RelatedArtistsContext()
|
||||
m_relatedModel->setColumnStyle( TreeModel::TrackOnly );
|
||||
m_relatedView->setTreeModel( m_relatedModel );
|
||||
m_relatedView->setVerticalScrollBarPolicy( Qt::ScrollBarAlwaysOff );
|
||||
m_relatedView->setSortingEnabled( false );
|
||||
m_relatedView->proxyModel()->sort( -1 );
|
||||
|
||||
QPalette pal = m_relatedView->palette();
|
||||
pal.setColor( QPalette::Window, QColor( 0, 0, 0, 0 ) );
|
||||
|
@ -85,7 +85,7 @@ InfoBar::InfoBar( QWidget* parent )
|
||||
m_autoUpdate->setText( tr( "Automatically update" ) );
|
||||
m_autoUpdate->setLayoutDirection( Qt::RightToLeft );
|
||||
m_autoUpdate->setPalette( whitePal );
|
||||
connect( m_autoUpdate, SIGNAL( stateChanged( int ) ), this, SIGNAL( autoUpdateChanged( int ) ) );
|
||||
connect( m_autoUpdate, SIGNAL( toggled( bool ) ), this, SIGNAL( autoUpdateChanged( bool ) ) );
|
||||
|
||||
ui->horizontalLayout->addWidget( m_autoUpdate );
|
||||
|
||||
|
@ -60,7 +60,7 @@ public slots:
|
||||
void setAutoUpdateAvailable( bool b );
|
||||
signals:
|
||||
void filterTextChanged( const QString& filter );
|
||||
void autoUpdateChanged( int state );
|
||||
void autoUpdateChanged( bool checked );
|
||||
|
||||
protected:
|
||||
void changeEvent( QEvent* e );
|
||||
|
@ -597,7 +597,9 @@ EchonestGenerator::sentenceSummary()
|
||||
suffix = ", ";
|
||||
else
|
||||
suffix = ".";
|
||||
} else
|
||||
} else if ( i < required.size() - 2 ) // An item in the list that is before the second to last one, don't use ", and", we only want that for the last item
|
||||
suffix += ", ";
|
||||
else
|
||||
suffix += ", and ";
|
||||
}
|
||||
sentence += center + suffix;
|
||||
|
@ -116,7 +116,7 @@ ViewManager::ViewManager( QObject* parent )
|
||||
|
||||
connect( &m_filterTimer, SIGNAL( timeout() ), SLOT( applyFilter() ) );
|
||||
connect( m_infobar, SIGNAL( filterTextChanged( QString ) ), SLOT( setFilter( QString ) ) );
|
||||
connect( m_infobar, SIGNAL( autoUpdateChanged( int ) ), SLOT( autoUpdateChanged( int ) ) );
|
||||
connect( m_infobar, SIGNAL( autoUpdateChanged( bool ) ), SLOT( autoUpdateChanged( bool ) ) );
|
||||
|
||||
connect( this, SIGNAL( tomahawkLoaded() ), m_whatsHotWidget, SLOT( fetchData() ) );
|
||||
connect( this, SIGNAL( tomahawkLoaded() ), m_welcomeWidget, SLOT( loadData() ) );
|
||||
@ -569,9 +569,9 @@ ViewManager::applyFilter()
|
||||
|
||||
|
||||
void
|
||||
ViewManager::autoUpdateChanged( int state )
|
||||
ViewManager::autoUpdateChanged( bool toggled )
|
||||
{
|
||||
currentPage()->setAutoUpdate( state == Qt::Checked );
|
||||
currentPage()->setAutoUpdate( toggled );
|
||||
}
|
||||
|
||||
|
||||
|
@ -177,7 +177,7 @@ private slots:
|
||||
void setFilter( const QString& filter );
|
||||
void applyFilter();
|
||||
|
||||
void autoUpdateChanged( int );
|
||||
void autoUpdateChanged( bool );
|
||||
|
||||
void onWidgetDestroyed( QWidget* widget );
|
||||
|
||||
|
@ -296,6 +296,7 @@ CategoryAddItem::playlistToRenameLoaded()
|
||||
QTimer::singleShot( 400, APP->mainWindow()->sourceTreeView(), SLOT( renamePlaylist() ) );
|
||||
|
||||
disconnect( pl, SIGNAL( dynamicRevisionLoaded( Tomahawk::DynamicPlaylistRevision ) ), this, SLOT( playlistToRenameLoaded() ) );
|
||||
disconnect( pl, SIGNAL( revisionLoaded( Tomahawk::PlaylistRevision ) ), this, SLOT( playlistToRenameLoaded() ) );
|
||||
}
|
||||
|
||||
|
||||
@ -307,8 +308,7 @@ CategoryAddItem::parsedDroppedTracks( const QList< query_ptr >& tracks )
|
||||
playlist_ptr newpl = Playlist::create( SourceList::instance()->getLocal(), uuid(), "New Playlist", "", SourceList::instance()->getLocal()->friendlyName(), false, tracks );
|
||||
ViewManager::instance()->show( newpl );
|
||||
|
||||
// Give a shot to try to rename it. The playlist has to be created first. ugly.
|
||||
QTimer::singleShot( 300, APP->mainWindow()->sourceTreeView(), SLOT( renamePlaylist() ) );
|
||||
connect( newpl.data(), SIGNAL( revisionLoaded( Tomahawk::PlaylistRevision ) ), this, SLOT( playlistToRenameLoaded() ) );
|
||||
} else if( m_categoryType == SourcesModel::StationsCategory ) {
|
||||
// seed the playlist with these song or artist filters
|
||||
QString name;
|
||||
|
@ -99,7 +99,7 @@ SourceTreeView::SourceTreeView( QWidget* parent )
|
||||
|
||||
m_model = new SourcesModel( this );
|
||||
m_proxyModel = new SourcesProxyModel( m_model, this );
|
||||
connect( m_proxyModel, SIGNAL( selectRequest( QPersistentModelIndex ) ), SLOT( selectRequest( QPersistentModelIndex ) ) );
|
||||
connect( m_proxyModel, SIGNAL( selectRequest( QPersistentModelIndex ) ), SLOT( selectRequest( QPersistentModelIndex ) ), Qt::QueuedConnection );
|
||||
connect( m_proxyModel, SIGNAL( expandRequest( QPersistentModelIndex ) ), SLOT( expandRequest( QPersistentModelIndex ) ) );
|
||||
connect( m_proxyModel, SIGNAL( toggleExpandRequest( QPersistentModelIndex ) ), SLOT( toggleExpandRequest( QPersistentModelIndex ) ) );
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user