mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-03-14 12:59:41 +01:00
* Abort when trying to add an empty set of tracks to the CollectionFlatModel.
This commit is contained in:
parent
7a51516092
commit
92b6865a7e
@ -130,6 +130,9 @@ CollectionFlatModel::removeCollection( const collection_ptr& collection )
|
|||||||
void
|
void
|
||||||
CollectionFlatModel::onTracksAdded( const QList<Tomahawk::query_ptr>& tracks, const Tomahawk::collection_ptr& collection )
|
CollectionFlatModel::onTracksAdded( const QList<Tomahawk::query_ptr>& tracks, const Tomahawk::collection_ptr& collection )
|
||||||
{
|
{
|
||||||
|
if ( !tracks.count() )
|
||||||
|
return;
|
||||||
|
|
||||||
int c = rowCount( QModelIndex() );
|
int c = rowCount( QModelIndex() );
|
||||||
QPair< int, int > crows;
|
QPair< int, int > crows;
|
||||||
crows.first = c;
|
crows.first = c;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user