Only update di.fm, sky.fm and somafm tree items if they've already been expanded by the user. Fixes duplicate radio streams appearing on first run if the user uses global search before looking in the Internet tab.
This commit is contained in:
parent
53f1f6509b
commit
df8bafe161
|
@ -121,7 +121,10 @@ void DigitallyImportedServiceBase::RefreshStreamsFinished(QNetworkReply* reply,
|
|||
|
||||
saved_channels_.Update(channels);
|
||||
|
||||
// Only update the item's children if it's already been expanded
|
||||
if (root_->hasChildren())
|
||||
PopulateStreams();
|
||||
|
||||
emit StreamsChanged();
|
||||
}
|
||||
|
||||
|
|
|
@ -121,7 +121,11 @@ void SomaFMService::RefreshStreamsFinished(QNetworkReply* reply, int task_id) {
|
|||
}
|
||||
|
||||
streams_.Update(list);
|
||||
|
||||
// Only update the item's children if it's already been expanded
|
||||
if (root_->hasChildren())
|
||||
PopulateStreams();
|
||||
|
||||
emit StreamsChanged();
|
||||
}
|
||||
|
||||
|
|
|
@ -1015,7 +1015,7 @@ msgstr ""
|
|||
msgid "Configure library..."
|
||||
msgstr ""
|
||||
|
||||
#: internet/digitallyimportedservicebase.cpp:182
|
||||
#: internet/digitallyimportedservicebase.cpp:185
|
||||
#: ../bin/src/ui_globalsearchsettingspage.h:174
|
||||
msgid "Configure..."
|
||||
msgstr ""
|
||||
|
@ -1618,7 +1618,7 @@ msgstr ""
|
|||
msgid "Error loading %1"
|
||||
msgstr ""
|
||||
|
||||
#: internet/digitallyimportedservicebase.cpp:204
|
||||
#: internet/digitallyimportedservicebase.cpp:207
|
||||
#: internet/digitallyimportedurlhandler.cpp:73
|
||||
msgid "Error loading di.fm playlist"
|
||||
msgstr ""
|
||||
|
@ -2766,7 +2766,7 @@ msgstr ""
|
|||
msgid "Only show the first"
|
||||
msgstr ""
|
||||
|
||||
#: internet/digitallyimportedservicebase.cpp:175
|
||||
#: internet/digitallyimportedservicebase.cpp:178
|
||||
#, qt-format
|
||||
msgid "Open %1 in browser"
|
||||
msgstr ""
|
||||
|
@ -3164,7 +3164,7 @@ msgstr ""
|
|||
msgid "Refresh station list"
|
||||
msgstr ""
|
||||
|
||||
#: internet/digitallyimportedservicebase.cpp:178
|
||||
#: internet/digitallyimportedservicebase.cpp:181
|
||||
msgid "Refresh streams"
|
||||
msgstr ""
|
||||
|
||||
|
|
Loading…
Reference in New Issue