1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-12-23 01:55:48 -05:00

Update default settings. Tweak UI.

This commit is contained in:
srcejon 2024-02-14 14:13:04 +00:00
parent e6e4d1661e
commit b046eac470
4 changed files with 35 additions and 13 deletions

View File

@ -50,13 +50,13 @@
ecliptic: "false",
eclipticOverviewText: "false",
eclipticGrid: "false",
eclipticGridText: "false",
altAzGrid: "false",
altAzGridText: "false",
eclipticGridText: "true",
altAzGrid: "true",
altAzGridText: "true",
equatorialGrid: "false",
equatorialGridText: "false",
equatorialGridText: "true",
galacticGrid: "false",
galacticGridText: "false",
galacticGridText: "true",
precessionChart: "false",
iss: "false",
solarSystemCosmos: "false",

View File

@ -341,6 +341,11 @@ void SkyMapGUI::on_source_currentIndexChanged(int index)
{
m_settings.m_source = ui->source->currentText();
applySetting("source");
ui->track->setEnabled(true);
}
else
{
ui->track->setEnabled(false);
}
}
@ -401,8 +406,14 @@ void SkyMapGUI::displaySettings()
}
ui->track->setChecked(m_settings.m_track);
idx = ui->source->findText(m_settings.m_source);
if (idx >= 0) {
if (idx >= 0)
{
ui->source->setCurrentIndex(idx);
ui->track->setEnabled(true);
}
else
{
ui->track->setEnabled(false);
}
initSkyMap();
getRollupContents()->restoreState(m_rollupState);
@ -1028,10 +1039,15 @@ void SkyMapGUI::updateSourceList()
// Select current setting, if exists
// If not, make sure nothing selected, as channel may be created later on
int idx = ui->source->findText(m_settings.m_source);
if (idx >= 0) {
if (idx >= 0)
{
ui->source->setCurrentIndex(idx);
} else {
ui->track->setEnabled(true);
}
else
{
ui->source->setCurrentIndex(-1);
ui->track->setEnabled(false);
}
ui->source->blockSignals(false);

View File

@ -260,12 +260,18 @@
</item>
<item>
<widget class="QComboBox" name="source">
<property name="minimumSize">
<size>
<width>120</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Source feature to get target from</string>
</property>
<item>
<property name="text">
<string>None</string>
<string>F0:1 StarTracker</string>
</property>
</item>
</widget>

View File

@ -77,11 +77,11 @@ void SkyMapSettings::resetToDefaults()
{"ecliptic", false},
{"eclipticOverviewText", false},
{"eclipticGrid", false},
{"eclipticGridText", false},
{"altAzGrid", false},
{"altAzGridText", false},
{"eclipticGridText", true},
{"altAzGrid", true},
{"altAzGridText", true},
{"galacticGrid", false},
{"galacticGridText", false},
{"galacticGridText", true},
{"elevationModel", false},
{"earthSky", false},
{"horizon", false},