Don't fetch magnatune library until service is expanded. Fixes issue 3440
This commit is contained in:
parent
f7cccb26fa
commit
465015fe3c
|
@ -129,6 +129,9 @@ void MagnatuneService::LazyPopulate(QStandardItem* item) {
|
|||
switch (item->data(InternetModel::Role_Type).toInt()) {
|
||||
case InternetModel::Type_Service:
|
||||
library_model_->Init();
|
||||
if (total_song_count_ == 0 && !load_database_task_id_) {
|
||||
ReloadDatabase();
|
||||
}
|
||||
model()->merged_model()->AddSubModel(item->index(), library_sort_model_);
|
||||
break;
|
||||
|
||||
|
@ -139,9 +142,6 @@ void MagnatuneService::LazyPopulate(QStandardItem* item) {
|
|||
|
||||
void MagnatuneService::UpdateTotalSongCount(int count) {
|
||||
total_song_count_ = count;
|
||||
if (total_song_count_ == 0 && !load_database_task_id_) {
|
||||
ReloadDatabase();
|
||||
}
|
||||
}
|
||||
|
||||
void MagnatuneService::ReloadDatabase() {
|
||||
|
|
Loading…
Reference in New Issue