Add SomaFM and Radio Paradise to scrobbler sources

This commit is contained in:
Jonas Kvinge
2021-07-11 05:18:56 +02:00
parent b053f99690
commit 3960c7d8e6
3 changed files with 53 additions and 36 deletions

View File

@@ -94,7 +94,9 @@ void AudioScrobbler::ReloadSettings() {
<< Song::Source_Stream
<< Song::Source_Tidal
<< Song::Source_Subsonic
<< Song::Source_Qobuz;
<< Song::Source_Qobuz
<< Song::Source_SomaFM
<< Song::Source_RadioParadise;
}
else {
for (const QString &source : sources) {

View File

@@ -108,6 +108,8 @@ void ScrobblerSettingsPage::Load() {
ui_->checkbox_source_tidal->setChecked(scrobbler_->sources().contains(Song::Source_Tidal));
ui_->checkbox_source_qobuz->setChecked(scrobbler_->sources().contains(Song::Source_Qobuz));
ui_->checkbox_source_stream->setChecked(scrobbler_->sources().contains(Song::Source_Stream));
ui_->checkbox_source_somafm->setChecked(scrobbler_->sources().contains(Song::Source_SomaFM));
ui_->checkbox_source_radioparadise->setChecked(scrobbler_->sources().contains(Song::Source_RadioParadise));
ui_->checkbox_source_unknown->setChecked(scrobbler_->sources().contains(Song::Source_Unknown));
ui_->checkbox_lastfm_enable->setChecked(lastfmscrobbler_->IsEnabled());
@@ -149,6 +151,8 @@ void ScrobblerSettingsPage::Save() {
if (ui_->checkbox_source_tidal->isChecked()) sources << Song::TextForSource(Song::Source_Tidal);
if (ui_->checkbox_source_qobuz->isChecked()) sources << Song::TextForSource(Song::Source_Qobuz);
if (ui_->checkbox_source_stream->isChecked()) sources << Song::TextForSource(Song::Source_Stream);
if (ui_->checkbox_source_somafm->isChecked()) sources << Song::TextForSource(Song::Source_SomaFM);
if (ui_->checkbox_source_radioparadise->isChecked()) sources << Song::TextForSource(Song::Source_RadioParadise);
if (ui_->checkbox_source_unknown->isChecked()) sources << Song::TextForSource(Song::Source_Unknown);
s.setValue("sources", sources);

View File

@@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>460</width>
<height>1009</height>
<height>1075</height>
</rect>
</property>
<property name="windowTitle">
@@ -135,34 +135,6 @@
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QCheckBox" name="checkbox_source_local">
<property name="text">
<string>Local file</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QCheckBox" name="checkbox_source_device">
<property name="text">
<string>Device</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QCheckBox" name="checkbox_source_cdda">
<property name="text">
<string>CDDA</string>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QCheckBox" name="checkbox_source_stream">
<property name="text">
<string>Stream</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QCheckBox" name="checkbox_source_subsonic">
<property name="text">
@@ -170,21 +142,63 @@
</property>
</widget>
</item>
<item row="1" column="1">
<item row="2" column="0">
<widget class="QCheckBox" name="checkbox_source_local">
<property name="text">
<string>Local file</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QCheckBox" name="checkbox_source_tidal">
<property name="text">
<string>Tidal</string>
</property>
</widget>
</item>
<item row="2" column="1">
<item row="3" column="0">
<widget class="QCheckBox" name="checkbox_source_device">
<property name="text">
<string>Device</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QCheckBox" name="checkbox_source_qobuz">
<property name="text">
<string>Qobuz</string>
</property>
</widget>
</item>
<item row="3" column="1">
<item row="4" column="0">
<widget class="QCheckBox" name="checkbox_source_cdda">
<property name="text">
<string>CDDA</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QCheckBox" name="checkbox_source_somafm">
<property name="text">
<string>SomaFM</string>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QCheckBox" name="checkbox_source_stream">
<property name="text">
<string>Stream</string>
</property>
</widget>
</item>
<item row="5" column="1">
<widget class="QCheckBox" name="checkbox_source_radioparadise">
<property name="text">
<string>Radio Paradise</string>
</property>
</widget>
</item>
<item row="6" column="0">
<widget class="QCheckBox" name="checkbox_source_unknown">
<property name="text">
<string>Unknown</string>
@@ -412,12 +426,9 @@
<tabstop>checkbox_source_collection</tabstop>
<tabstop>checkbox_source_local</tabstop>
<tabstop>checkbox_source_device</tabstop>
<tabstop>checkbox_source_cdda</tabstop>
<tabstop>checkbox_source_stream</tabstop>
<tabstop>checkbox_source_subsonic</tabstop>
<tabstop>checkbox_source_tidal</tabstop>
<tabstop>checkbox_source_qobuz</tabstop>
<tabstop>checkbox_source_unknown</tabstop>
<tabstop>checkbox_lastfm_enable</tabstop>
<tabstop>checkbox_lastfm_https</tabstop>
<tabstop>button_lastfm_login</tabstop>