mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-11 16:44:05 +02:00
* Make sure all models emit a select request on first load.
This commit is contained in:
@@ -711,11 +711,10 @@ PlayableModel::insertInternal( const QList< T >& items, int row, const QList< To
|
||||
|
||||
emit endInsertRows();
|
||||
emit itemCountChanged( rowCount( QModelIndex() ) );
|
||||
|
||||
emit selectRequest( index( 0, 0, parent ) );
|
||||
if ( parent.isValid() )
|
||||
{
|
||||
emit selectRequest( index( 0, 0, parent ) );
|
||||
emit expandRequest( parent );
|
||||
}
|
||||
|
||||
finishLoading();
|
||||
}
|
||||
|
@@ -117,7 +117,6 @@ PlayableProxyModel::setSourcePlayableModel( PlayableModel* sourceModel )
|
||||
}
|
||||
|
||||
m_model = sourceModel;
|
||||
|
||||
if ( m_model )
|
||||
{
|
||||
connect( m_model, SIGNAL( loadingStarted() ), SIGNAL( loadingStarted() ) );
|
||||
|
@@ -375,6 +375,7 @@ TreeModel::onTracksAdded( const QList<Tomahawk::query_ptr>& tracks, const QModel
|
||||
}
|
||||
|
||||
emit endInsertRows();
|
||||
emit selectRequest( index( 0, 0, parent ) );
|
||||
}
|
||||
|
||||
|
||||
|
@@ -27,8 +27,6 @@
|
||||
#include "database/Database.h"
|
||||
#include "playlist/TreeModel.h"
|
||||
#include "playlist/PlayableModel.h"
|
||||
#include "playlist/AlbumItemDelegate.h"
|
||||
#include "playlist/GridItemDelegate.h"
|
||||
#include "Source.h"
|
||||
#include "MetaPlaylistInterface.h"
|
||||
#include "playlist/TrackView.h"
|
||||
|
Reference in New Issue
Block a user