From b046eac470e8ba537f51a6a87e870ff38081dd30 Mon Sep 17 00:00:00 2001 From: srcejon Date: Wed, 14 Feb 2024 14:13:04 +0000 Subject: [PATCH] Update default settings. Tweak UI. --- plugins/feature/skymap/html/wwt.html | 10 +++++----- plugins/feature/skymap/skymapgui.cpp | 22 +++++++++++++++++++--- plugins/feature/skymap/skymapgui.ui | 8 +++++++- plugins/feature/skymap/skymapsettings.cpp | 8 ++++---- 4 files changed, 35 insertions(+), 13 deletions(-) diff --git a/plugins/feature/skymap/html/wwt.html b/plugins/feature/skymap/html/wwt.html index fe1738cfa..5d8640d67 100644 --- a/plugins/feature/skymap/html/wwt.html +++ b/plugins/feature/skymap/html/wwt.html @@ -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", diff --git a/plugins/feature/skymap/skymapgui.cpp b/plugins/feature/skymap/skymapgui.cpp index 6e251338a..72ba4d145 100644 --- a/plugins/feature/skymap/skymapgui.cpp +++ b/plugins/feature/skymap/skymapgui.cpp @@ -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); diff --git a/plugins/feature/skymap/skymapgui.ui b/plugins/feature/skymap/skymapgui.ui index 2adaffcf5..4845b04a0 100644 --- a/plugins/feature/skymap/skymapgui.ui +++ b/plugins/feature/skymap/skymapgui.ui @@ -260,12 +260,18 @@ + + + 120 + 0 + + Source feature to get target from - None + F0:1 StarTracker diff --git a/plugins/feature/skymap/skymapsettings.cpp b/plugins/feature/skymap/skymapsettings.cpp index c01243bbc..56bc21b65 100644 --- a/plugins/feature/skymap/skymapsettings.cpp +++ b/plugins/feature/skymap/skymapsettings.cpp @@ -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},