1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-11 16:44:05 +02:00

* Load albums when opening collection.

This commit is contained in:
Christian Muehlhaeuser
2014-08-27 21:28:59 +02:00
parent a0e1e9c67f
commit 0a9a70ba38

View File

@@ -295,12 +295,16 @@ ViewManager::show( const Tomahawk::collection_ptr& collection )
view->columnView()->proxyModel()->setStyle( PlayableProxyModel::Collection ); view->columnView()->proxyModel()->setStyle( PlayableProxyModel::Collection );
TreeModel* model = new TreeModel(); TreeModel* model = new TreeModel();
PlayableModel* flatModel = new PlayableModel(); PlayableModel* flatModel = new PlayableModel();
PlayableModel* albumModel = new PlayableModel();
view->setTreeModel( model ); view->setTreeModel( model );
view->setFlatModel( flatModel ); view->setFlatModel( flatModel );
view->setAlbumModel( albumModel );
model->addCollection( collection ); model->addCollection( collection );
flatModel->appendTracks( collection ); flatModel->appendTracks( collection );
albumModel->appendAlbums( collection );
setPage( view ); setPage( view );
if ( !collection.isNull() ) if ( !collection.isNull() )