ConfigurationDialog.cpp   ConfigurationDialog.cpp 
skipping to change at line 46 skipping to change at line 46
#include "StelUtils.hpp" #include "StelUtils.hpp"
#include "StelCore.hpp" #include "StelCore.hpp"
#include "StelMovementMgr.hpp" #include "StelMovementMgr.hpp"
#include "StelModuleMgr.hpp" #include "StelModuleMgr.hpp"
#include "StelGui.hpp" #include "StelGui.hpp"
#include "StelGuiItems.hpp" #include "StelGuiItems.hpp"
#include "StelLocation.hpp" #include "StelLocation.hpp"
#include "StelSkyCultureMgr.hpp" #include "StelSkyCultureMgr.hpp"
#include "StelSkyLayerMgr.hpp" #include "StelSkyLayerMgr.hpp"
#include "ConstellationMgr.hpp" #include "ConstellationMgr.hpp"
#include "AsterismMgr.hpp"
#include "StarMgr.hpp" #include "StarMgr.hpp"
#include "NebulaMgr.hpp" #include "NebulaMgr.hpp"
#include "Planet.hpp"
#ifndef DISABLE_SCRIPTING #ifndef DISABLE_SCRIPTING
#include "StelScriptMgr.hpp" #include "StelScriptMgr.hpp"
#endif #endif
#include "LabelMgr.hpp" #include "LabelMgr.hpp"
#include "ScreenImageMgr.hpp" #include "ScreenImageMgr.hpp"
#include "SkyGui.hpp" #include "SkyGui.hpp"
#include "StelJsonParser.hpp" #include "StelJsonParser.hpp"
#include "StelTranslator.hpp" #include "StelTranslator.hpp"
#include "EphemWrapper.hpp" #include "EphemWrapper.hpp"
#include "ToastMgr.hpp" #include "ToastMgr.hpp"
skipping to change at line 73 skipping to change at line 75
#include <QComboBox> #include <QComboBox>
#include <QDir> #include <QDir>
#include <QDesktopWidget> #include <QDesktopWidget>
ConfigurationDialog::ConfigurationDialog(StelGui* agui, QObject* parent) ConfigurationDialog::ConfigurationDialog(StelGui* agui, QObject* parent)
: StelDialog("Configuration", parent) : StelDialog("Configuration", parent)
, isDownloadingStarCatalog(false) , isDownloadingStarCatalog(false)
, nextStarCatalogToDownloadIndex(0) , nextStarCatalogToDownloadIndex(0)
, starCatalogsCount(0) , starCatalogsCount(0)
, hasDownloadedStarCatalog(false) , hasDownloadedStarCatalog(false)
, starCatalogDownloadReply(NULL) , starCatalogDownloadReply(Q_NULLPTR)
, currentDownloadFile(NULL) , currentDownloadFile(Q_NULLPTR)
, progressBar(NULL) , progressBar(Q_NULLPTR)
, gui(agui) , gui(agui)
, customDeltaTEquationDialog(NULL) , customDeltaTEquationDialog(Q_NULLPTR)
, savedProjectionType(StelApp::getInstance().getCore()->getCurrentPr ojectionType()) , savedProjectionType(StelApp::getInstance().getCore()->getCurrentPr ojectionType())
{ {
ui = new Ui_configurationDialogForm; ui = new Ui_configurationDialogForm;
} }
ConfigurationDialog::~ConfigurationDialog() ConfigurationDialog::~ConfigurationDialog()
{ {
delete ui; delete ui;
ui = NULL; ui = Q_NULLPTR;
delete customDeltaTEquationDialog; delete customDeltaTEquationDialog;
customDeltaTEquationDialog = NULL; customDeltaTEquationDialog = Q_NULLPTR;
} }
void ConfigurationDialog::retranslate() void ConfigurationDialog::retranslate()
{ {
if (dialog) { if (dialog) {
ui->retranslateUi(dialog); ui->retranslateUi(dialog);
//Initial FOV and direction on the "Main" page //Initial FOV and direction on the "Main" page
updateConfigLabels(); updateConfigLabels();
skipping to change at line 200 skipping to change at line 202
else if (gui->getInfoTextFilters() == StelObject::AllInfo) else if (gui->getInfoTextFilters() == StelObject::AllInfo)
{ {
ui->allSelectedInfoRadio->setChecked(true); ui->allSelectedInfoRadio->setChecked(true);
} }
else else
{ {
ui->customSelectedInfoRadio->setChecked(true); ui->customSelectedInfoRadio->setChecked(true);
} }
updateSelectedInfoCheckBoxes(); updateSelectedInfoCheckBoxes();
// Additional settings for selected object info
connectBoolProperty(ui->checkBoxUMSurfaceBrightness, "NebulaMgr.flag
SurfaceBrightnessArcsecUsage");
connect(ui->noSelectedInfoRadio, SIGNAL(released()), this, SLOT(setN oSelectedInfo())); connect(ui->noSelectedInfoRadio, SIGNAL(released()), this, SLOT(setN oSelectedInfo()));
connect(ui->allSelectedInfoRadio, SIGNAL(released()), this, SLOT(set AllSelectedInfo())); connect(ui->allSelectedInfoRadio, SIGNAL(released()), this, SLOT(set AllSelectedInfo()));
connect(ui->briefSelectedInfoRadio, SIGNAL(released()), this, SLOT(s etBriefSelectedInfo())); connect(ui->briefSelectedInfoRadio, SIGNAL(released()), this, SLOT(s etBriefSelectedInfo()));
connect(ui->buttonGroupDisplayedFields, SIGNAL(buttonClicked(int)), this, SLOT(setSelectedInfoFromCheckBoxes())); connect(ui->buttonGroupDisplayedFields, SIGNAL(buttonClicked(int)), this, SLOT(setSelectedInfoFromCheckBoxes()));
// Navigation tab // Navigation tab
// Startup time // Startup time
if (core->getStartupTimeMode()=="actual") if (core->getStartupTimeMode()=="actual")
ui->systemTimeRadio->setChecked(true); ui->systemTimeRadio->setChecked(true);
else if (core->getStartupTimeMode()=="today") else if (core->getStartupTimeMode()=="today")
skipping to change at line 296 skipping to change at line 301
ui->showNebulaBgButtonCheckbox->setChecked(gui->getFlagShowNebulaBac kgroundButton()); ui->showNebulaBgButtonCheckbox->setChecked(gui->getFlagShowNebulaBac kgroundButton());
connect(ui->showNebulaBgButtonCheckbox, SIGNAL(toggled(bool)), gui, SLOT(setFlagShowNebulaBackgroundButton(bool))); connect(ui->showNebulaBgButtonCheckbox, SIGNAL(toggled(bool)), gui, SLOT(setFlagShowNebulaBackgroundButton(bool)));
ui->showToastSurveyButtonCheckbox->setChecked(gui->getFlagShowToastS urveyButton()); ui->showToastSurveyButtonCheckbox->setChecked(gui->getFlagShowToastS urveyButton());
connect(ui->showToastSurveyButtonCheckbox, SIGNAL(toggled(bool)), gu i, SLOT(setFlagShowToastSurveyButton(bool))); connect(ui->showToastSurveyButtonCheckbox, SIGNAL(toggled(bool)), gu i, SLOT(setFlagShowToastSurveyButton(bool)));
ui->showBookmarksButtonCheckBox->setChecked(gui->getFlagShowBookmark sButton()); ui->showBookmarksButtonCheckBox->setChecked(gui->getFlagShowBookmark sButton());
connect(ui->showBookmarksButtonCheckBox, SIGNAL(toggled(bool)), gui, SLOT(setFlagShowBookmarksButton(bool))); connect(ui->showBookmarksButtonCheckBox, SIGNAL(toggled(bool)), gui, SLOT(setFlagShowBookmarksButton(bool)));
ui->showICRSGridButtonCheckBox->setChecked(gui->getFlagShowICRSGridB
utton());
connect(ui->showICRSGridButtonCheckBox, SIGNAL(toggled(bool)), gui,
SLOT(setFlagShowICRSGridButton(bool)));
ui->showGalacticGridButtonCheckBox->setChecked(gui->getFlagShowGalac
ticGridButton());
connect(ui->showGalacticGridButtonCheckBox, SIGNAL(toggled(bool)), g
ui, SLOT(setFlagShowGalacticGridButton(bool)));
ui->showEclipticGridButtonCheckBox->setChecked(gui->getFlagShowEclip
ticGridButton());
connect(ui->showEclipticGridButtonCheckBox, SIGNAL(toggled(bool)), g
ui, SLOT(setFlagShowEclipticGridButton(bool)));
ui->showConstellationBoundariesButtonCheckBox->setChecked(gui->getFl
agShowConstellationBoundariesButton());
connect(ui->showConstellationBoundariesButtonCheckBox, SIGNAL(toggle
d(bool)), gui, SLOT(setFlagShowConstellationBoundariesButton(bool)));
ui->decimalDegreeCheckBox->setChecked(StelApp::getInstance().getFlag ShowDecimalDegrees()); ui->decimalDegreeCheckBox->setChecked(StelApp::getInstance().getFlag ShowDecimalDegrees());
connect(ui->decimalDegreeCheckBox, SIGNAL(toggled(bool)), gui, SLOT( setFlagShowDecimalDegrees(bool))); connect(ui->decimalDegreeCheckBox, SIGNAL(toggled(bool)), gui, SLOT( setFlagShowDecimalDegrees(bool)));
ui->azimuthFromSouthcheckBox->setChecked(StelApp::getInstance().getF lagSouthAzimuthUsage()); ui->azimuthFromSouthcheckBox->setChecked(StelApp::getInstance().getF lagSouthAzimuthUsage());
connect(ui->azimuthFromSouthcheckBox, SIGNAL(toggled(bool)), this, S LOT(updateStartPointForAzimuth(bool))); connect(ui->azimuthFromSouthcheckBox, SIGNAL(toggled(bool)), this, S LOT(updateStartPointForAzimuth(bool)));
ui->mouseTimeoutCheckbox->setChecked(StelMainView::getInstance().get FlagCursorTimeout()); ui->mouseTimeoutCheckbox->setChecked(StelMainView::getInstance().get FlagCursorTimeout());
ui->mouseTimeoutSpinBox->setValue(StelMainView::getInstance().getCur sorTimeout()); ui->mouseTimeoutSpinBox->setValue(StelMainView::getInstance().getCur sorTimeout());
connect(ui->mouseTimeoutCheckbox, SIGNAL(clicked()), this, SLOT(curs orTimeOutChanged())); connect(ui->mouseTimeoutCheckbox, SIGNAL(clicked()), this, SLOT(curs orTimeOutChanged()));
connect(ui->mouseTimeoutCheckbox, SIGNAL(toggled(bool)), this, SLOT( cursorTimeOutChanged())); connect(ui->mouseTimeoutCheckbox, SIGNAL(toggled(bool)), this, SLOT( cursorTimeOutChanged()));
connect(ui->mouseTimeoutSpinBox, SIGNAL(valueChanged(double)), this, SLOT(cursorTimeOutChanged(double))); connect(ui->mouseTimeoutSpinBox, SIGNAL(valueChanged(double)), this, SLOT(cursorTimeOutChanged(double)));
ui->useButtonsBackgroundCheckBox->setChecked(StelMainView::getInstan
ce().getFlagUseButtonsBackground());
connect(ui->useButtonsBackgroundCheckBox, SIGNAL(toggled(bool)), thi
s, SLOT(usageButtonsBackgroundChanged(bool)));
ui->indicationMountModeCheckBox->setChecked(mvmgr->getFlagIndication
MountMode());
connect(ui->indicationMountModeCheckBox, SIGNAL(toggled(bool)), mvmg
r, SLOT(setFlagIndicationMountMode(bool)));
// General Option Save // General Option Save
connect(ui->saveViewDirAsDefaultPushButton, SIGNAL(clicked()), this, SLOT(saveCurrentViewDirSettings())); connect(ui->saveViewDirAsDefaultPushButton, SIGNAL(clicked()), this, SLOT(saveCurrentViewDirSettings()));
connect(ui->saveSettingsAsDefaultPushButton, SIGNAL(clicked()), this , SLOT(saveAllSettings())); connect(ui->saveSettingsAsDefaultPushButton, SIGNAL(clicked()), this , SLOT(saveAllSettings()));
connect(ui->restoreDefaultsButton, SIGNAL(clicked()), this, SLOT(set DefaultViewOptions())); connect(ui->restoreDefaultsButton, SIGNAL(clicked()), this, SLOT(set DefaultViewOptions()));
// Screenshots // Screenshots
ui->screenshotDirEdit->setText(StelFileMgr::getScreenshotDir()); ui->screenshotDirEdit->setText(StelFileMgr::getScreenshotDir());
connect(ui->screenshotDirEdit, SIGNAL(textChanged(QString)), this, S LOT(selectScreenshotDir(QString))); connect(ui->screenshotDirEdit, SIGNAL(textChanged(QString)), this, S LOT(selectScreenshotDir(QString)));
connect(ui->screenshotBrowseButton, SIGNAL(clicked()), this, SLOT(br owseForScreenshotDir())); connect(ui->screenshotBrowseButton, SIGNAL(clicked()), this, SLOT(br owseForScreenshotDir()));
skipping to change at line 534 skipping to change at line 557
{ {
StelApp::getInstance().setFlagSouthAzimuthUsage(b); StelApp::getInstance().setFlagSouthAzimuthUsage(b);
} }
void ConfigurationDialog::cursorTimeOutChanged() void ConfigurationDialog::cursorTimeOutChanged()
{ {
StelMainView::getInstance().setFlagCursorTimeout(ui->mouseTimeoutChe ckbox->isChecked()); StelMainView::getInstance().setFlagCursorTimeout(ui->mouseTimeoutChe ckbox->isChecked());
StelMainView::getInstance().setCursorTimeout(ui->mouseTimeoutSpinBox ->value()); StelMainView::getInstance().setCursorTimeout(ui->mouseTimeoutSpinBox ->value());
} }
void ConfigurationDialog::usageButtonsBackgroundChanged(bool b)
{
StelMainView::getInstance().setFlagUseButtonsBackground(b);
emit StelMainView::getInstance().updateIconsRequested();
}
void ConfigurationDialog::browseForScreenshotDir() void ConfigurationDialog::browseForScreenshotDir()
{ {
QString oldScreenshorDir = StelFileMgr::getScreenshotDir(); QString oldScreenshorDir = StelFileMgr::getScreenshotDir();
QString newScreenshotDir = QFileDialog::getExistingDirectory(NULL, q _("Select screenshot directory"), oldScreenshorDir, QFileDialog::ShowDirsOn ly); QString newScreenshotDir = QFileDialog::getExistingDirectory(Q_NULLP TR, q_("Select screenshot directory"), oldScreenshorDir, QFileDialog::ShowD irsOnly);
if (!newScreenshotDir.isEmpty()) { if (!newScreenshotDir.isEmpty()) {
// remove trailing slash // remove trailing slash
if (newScreenshotDir.right(1) == "/") if (newScreenshotDir.right(1) == "/")
newScreenshotDir = newScreenshotDir.left(newScreensh otDir.length()-1); newScreenshotDir = newScreenshotDir.left(newScreensh otDir.length()-1);
ui->screenshotDirEdit->setText(newScreenshotDir); ui->screenshotDirEdit->setText(newScreenshotDir);
} }
} }
skipping to change at line 611 skipping to change at line 640
conf->setValue("astro/flag_nebula_magnitude_limit", propMgr->get StelPropertyValue("StelSkyDrawer.flagNebulaMagnitudeLimit").toBool()); conf->setValue("astro/flag_nebula_magnitude_limit", propMgr->get StelPropertyValue("StelSkyDrawer.flagNebulaMagnitudeLimit").toBool());
conf->setValue("astro/nebula_magnitude_limit", propMgr->get StelPropertyValue("StelSkyDrawer.customNebulaMagLimit").toFloat()); conf->setValue("astro/nebula_magnitude_limit", propMgr->get StelPropertyValue("StelSkyDrawer.customNebulaMagLimit").toFloat());
conf->setValue("viewing/use_luminance_adaptation", propMgr->get StelPropertyValue("StelSkyDrawer.flagLuminanceAdaptation").toBool()); conf->setValue("viewing/use_luminance_adaptation", propMgr->get StelPropertyValue("StelSkyDrawer.flagLuminanceAdaptation").toBool());
conf->setValue("astro/flag_planets", propMgr->get StelPropertyValue("SolarSystem.planetsDisplayed").toBool()); conf->setValue("astro/flag_planets", propMgr->get StelPropertyValue("SolarSystem.planetsDisplayed").toBool());
conf->setValue("astro/flag_planets_hints", propMgr->get StelPropertyValue("SolarSystem.flagHints").toBool()); conf->setValue("astro/flag_planets_hints", propMgr->get StelPropertyValue("SolarSystem.flagHints").toBool());
conf->setValue("astro/flag_planets_orbits", propMgr->get StelPropertyValue("SolarSystem.flagOrbits").toBool()); conf->setValue("astro/flag_planets_orbits", propMgr->get StelPropertyValue("SolarSystem.flagOrbits").toBool());
conf->setValue("viewing/flag_isolated_trails", propMgr->get StelPropertyValue("SolarSystem.flagIsolatedTrails").toBool()); conf->setValue("viewing/flag_isolated_trails", propMgr->get StelPropertyValue("SolarSystem.flagIsolatedTrails").toBool());
conf->setValue("viewing/flag_isolated_orbits", propMgr->get StelPropertyValue("SolarSystem.flagIsolatedOrbits").toBool()); conf->setValue("viewing/flag_isolated_orbits", propMgr->get StelPropertyValue("SolarSystem.flagIsolatedOrbits").toBool());
conf->setValue("astro/flag_light_travel_time", propMgr->get StelPropertyValue("SolarSystem.flagLightTravelTime").toBool()); conf->setValue("astro/flag_light_travel_time", propMgr->get StelPropertyValue("SolarSystem.flagLightTravelTime").toBool());
conf->setValue("viewing/flag_moon_scaled", propMgr->get StelPropertyValue("SolarSystem.flagMoonScale").toBool()); conf->setValue("viewing/flag_moon_scaled", propMgr->get StelPropertyValue("SolarSystem.flagMoonScale").toBool());
conf->setValue("viewing/moon_scale", propMgr->get conf->setValue("viewing/moon_scale", propMgr->get
StelPropertyValue("SolarSystem.moonScale").toDouble()); StelPropertyValue("SolarSystem.moonScale").toFloat());
conf->setValue("viewing/flag_minorbodies_scaled", propMgr->get
StelPropertyValue("SolarSystem.flagMinorBodyScale").toBool());
conf->setValue("viewing/minorbodies_scale", propMgr->get
StelPropertyValue("SolarSystem.minorBodyScale").toFloat());
conf->setValue("astro/meteor_zhr", propMgr->get StelPropertyValue("SporadicMeteorMgr.zhr").toInt()); conf->setValue("astro/meteor_zhr", propMgr->get StelPropertyValue("SporadicMeteorMgr.zhr").toInt());
conf->setValue("astro/flag_milky_way", propMgr->get StelPropertyValue("MilkyWay.flagMilkyWayDisplayed").toBool()); conf->setValue("astro/flag_milky_way", propMgr->get StelPropertyValue("MilkyWay.flagMilkyWayDisplayed").toBool());
conf->setValue("astro/milky_way_intensity", propMgr->get StelPropertyValue("MilkyWay.intensity").toDouble()); conf->setValue("astro/milky_way_intensity", propMgr->get StelPropertyValue("MilkyWay.intensity").toFloat());
conf->setValue("astro/flag_zodiacal_light", propMgr->get StelPropertyValue("ZodiacalLight.flagZodiacalLightDisplayed").toBool()); conf->setValue("astro/flag_zodiacal_light", propMgr->get StelPropertyValue("ZodiacalLight.flagZodiacalLightDisplayed").toBool());
conf->setValue("astro/zodiacal_light_intensity", propMgr->get StelPropertyValue("ZodiacalLight.intensity").toDouble()); conf->setValue("astro/zodiacal_light_intensity", propMgr->get StelPropertyValue("ZodiacalLight.intensity").toFloat());
conf->setValue("astro/flag_grs_custom", propMgr->get StelPropertyValue("SolarSystem.flagCustomGrsSettings").toBool()); conf->setValue("astro/flag_grs_custom", propMgr->get StelPropertyValue("SolarSystem.flagCustomGrsSettings").toBool());
conf->setValue("astro/grs_longitude", propMgr->get StelPropertyValue("SolarSystem.customGrsLongitude").toInt()); conf->setValue("astro/grs_longitude", propMgr->get StelPropertyValue("SolarSystem.customGrsLongitude").toInt());
conf->setValue("astro/grs_drift", propMgr->get StelPropertyValue("SolarSystem.customGrsDrift").toDouble()); conf->setValue("astro/grs_drift", propMgr->get StelPropertyValue("SolarSystem.customGrsDrift").toDouble());
conf->setValue("astro/grs_jd", propMgr->get StelPropertyValue("SolarSystem.customGrsJD").toDouble()); conf->setValue("astro/grs_jd", propMgr->get StelPropertyValue("SolarSystem.customGrsJD").toDouble());
conf->setValue("astro/flag_planets_labels", propMgr->get StelPropertyValue("SolarSystem.labelsDisplayed").toBool()); conf->setValue("astro/flag_planets_labels", propMgr->get StelPropertyValue("SolarSystem.labelsDisplayed").toBool());
conf->setValue("astro/labels_amount", propMgr->get StelPropertyValue("SolarSystem.labelsAmount").toDouble()); conf->setValue("astro/labels_amount", propMgr->get StelPropertyValue("SolarSystem.labelsAmount").toDouble());
conf->setValue("viewing/flag_planets_native_names", propMgr->get StelPropertyValue("SolarSystem.flagNativePlanetNames").toBool()); conf->setValue("viewing/flag_planets_native_names", propMgr->get StelPropertyValue("SolarSystem.flagNativePlanetNames").toBool());
conf->setValue("astro/flag_use_obj_models", propMgr->get
StelPropertyValue("SolarSystem.flagUseObjModels").toBool());
conf->setValue("astro/flag_show_obj_self_shadows", propMgr->get
StelPropertyValue("SolarSystem.flagShowObjSelfShadows").toBool());
conf->setValue("astro/apparent_magnitude_algorithm", Planet::getA
pparentMagnitudeAlgorithmString());
// view dialog / markings tab settings // view dialog / markings tab settings
conf->setValue("viewing/flag_gridlines", propMgr->get StelPropertyValue("GridLinesMgr.gridlinesDisplayed").toBool());
conf->setValue("viewing/flag_azimuthal_grid", propMgr->get StelPropertyValue("GridLinesMgr.azimuthalGridDisplayed").toBool()); conf->setValue("viewing/flag_azimuthal_grid", propMgr->get StelPropertyValue("GridLinesMgr.azimuthalGridDisplayed").toBool());
conf->setValue("viewing/flag_equatorial_grid", propMgr->get StelPropertyValue("GridLinesMgr.equatorGridDisplayed").toBool()); conf->setValue("viewing/flag_equatorial_grid", propMgr->get StelPropertyValue("GridLinesMgr.equatorGridDisplayed").toBool());
conf->setValue("viewing/flag_equatorial_J2000_grid", propMgr->get StelPropertyValue("GridLinesMgr.equatorJ2000GridDisplayed").toBool()); conf->setValue("viewing/flag_equatorial_J2000_grid", propMgr->get StelPropertyValue("GridLinesMgr.equatorJ2000GridDisplayed").toBool());
conf->setValue("viewing/flag_equator_line", propMgr->get StelPropertyValue("GridLinesMgr.equatorLineDisplayed").toBool()); conf->setValue("viewing/flag_equator_line", propMgr->get StelPropertyValue("GridLinesMgr.equatorLineDisplayed").toBool());
conf->setValue("viewing/flag_equator_J2000_line", propMgr->get StelPropertyValue("GridLinesMgr.equatorJ2000LineDisplayed").toBool()); conf->setValue("viewing/flag_equator_J2000_line", propMgr->get StelPropertyValue("GridLinesMgr.equatorJ2000LineDisplayed").toBool());
conf->setValue("viewing/flag_ecliptic_line", propMgr->get StelPropertyValue("GridLinesMgr.eclipticLineDisplayed").toBool()); conf->setValue("viewing/flag_ecliptic_line", propMgr->get StelPropertyValue("GridLinesMgr.eclipticLineDisplayed").toBool());
conf->setValue("viewing/flag_ecliptic_J2000_line", propMgr->get StelPropertyValue("GridLinesMgr.eclipticJ2000LineDisplayed").toBool()); conf->setValue("viewing/flag_ecliptic_J2000_line", propMgr->get StelPropertyValue("GridLinesMgr.eclipticJ2000LineDisplayed").toBool());
conf->setValue("viewing/flag_ecliptic_grid", propMgr->get StelPropertyValue("GridLinesMgr.eclipticGridDisplayed").toBool()); conf->setValue("viewing/flag_ecliptic_grid", propMgr->get StelPropertyValue("GridLinesMgr.eclipticGridDisplayed").toBool());
conf->setValue("viewing/flag_ecliptic_J2000_grid", propMgr->get StelPropertyValue("GridLinesMgr.eclipticJ2000GridDisplayed").toBool()); conf->setValue("viewing/flag_ecliptic_J2000_grid", propMgr->get StelPropertyValue("GridLinesMgr.eclipticJ2000GridDisplayed").toBool());
conf->setValue("viewing/flag_meridian_line", propMgr->get StelPropertyValue("GridLinesMgr.meridianLineDisplayed").toBool()); conf->setValue("viewing/flag_meridian_line", propMgr->get StelPropertyValue("GridLinesMgr.meridianLineDisplayed").toBool());
skipping to change at line 670 skipping to change at line 705
conf->setValue("viewing/flag_constellation_name", propMgr->get StelPropertyValue("ConstellationMgr.namesDisplayed").toBool()); conf->setValue("viewing/flag_constellation_name", propMgr->get StelPropertyValue("ConstellationMgr.namesDisplayed").toBool());
conf->setValue("viewing/flag_constellation_boundaries", propMgr->get StelPropertyValue("ConstellationMgr.boundariesDisplayed").toBool()); conf->setValue("viewing/flag_constellation_boundaries", propMgr->get StelPropertyValue("ConstellationMgr.boundariesDisplayed").toBool());
conf->setValue("viewing/flag_constellation_art", propMgr->get StelPropertyValue("ConstellationMgr.artDisplayed").toBool()); conf->setValue("viewing/flag_constellation_art", propMgr->get StelPropertyValue("ConstellationMgr.artDisplayed").toBool());
conf->setValue("viewing/flag_constellation_isolate_selected", propMg r->getStelPropertyValue("ConstellationMgr.isolateSelected").toBool()); conf->setValue("viewing/flag_constellation_isolate_selected", propMg r->getStelPropertyValue("ConstellationMgr.isolateSelected").toBool());
conf->setValue("viewing/flag_landscape_autoselection", propMgr->get StelPropertyValue("LandscapeMgr.flagLandscapeAutoSelection").toBool()); conf->setValue("viewing/flag_landscape_autoselection", propMgr->get StelPropertyValue("LandscapeMgr.flagLandscapeAutoSelection").toBool());
conf->setValue("viewing/flag_light_pollution_database", propMgr->get StelPropertyValue("LandscapeMgr.flagUseLightPollutionFromDatabase").toBool( )); conf->setValue("viewing/flag_light_pollution_database", propMgr->get StelPropertyValue("LandscapeMgr.flagUseLightPollutionFromDatabase").toBool( ));
conf->setValue("viewing/flag_atmosphere_auto_enable", propMgr->get StelPropertyValue("LandscapeMgr.flagAtmosphereAutoEnabling").toBool()); conf->setValue("viewing/flag_atmosphere_auto_enable", propMgr->get StelPropertyValue("LandscapeMgr.flagAtmosphereAutoEnabling").toBool());
conf->setValue("viewing/constellation_art_intensity", propMgr->get StelPropertyValue("ConstellationMgr.artIntensity").toFloat()); conf->setValue("viewing/constellation_art_intensity", propMgr->get StelPropertyValue("ConstellationMgr.artIntensity").toFloat());
conf->setValue("viewing/constellation_name_style", Constellatio nMgr::getConstellationDisplayStyleString(static_cast<ConstellationMgr::Cons tellationDisplayStyle> (propMgr->getStelPropertyValue("ConstellationMgr.con stellationDisplayStyle").toInt()) )); conf->setValue("viewing/constellation_name_style", Constellatio nMgr::getConstellationDisplayStyleString(static_cast<ConstellationMgr::Cons tellationDisplayStyle> (propMgr->getStelPropertyValue("ConstellationMgr.con stellationDisplayStyle").toInt()) ));
conf->setValue("viewing/constellation_line_thickness", propMgr->get StelPropertyValue("ConstellationMgr.constellationLineThickness").toFloat()) ; conf->setValue("viewing/constellation_line_thickness", propMgr->get StelPropertyValue("ConstellationMgr.constellationLineThickness").toFloat()) ;
conf->setValue("viewing/flag_asterism_drawing", propMgr->get
StelPropertyValue("AsterismMgr.linesDisplayed").toBool());
conf->setValue("viewing/flag_asterism_name", propMgr->get
StelPropertyValue("AsterismMgr.namesDisplayed").toBool());
conf->setValue("viewing/asterism_line_thickness", propMgr->get
StelPropertyValue("AsterismMgr.asterismLineThickness").toFloat());
conf->setValue("viewing/flag_night", StelApp::get Instance().getVisionModeNight()); conf->setValue("viewing/flag_night", StelApp::get Instance().getVisionModeNight());
conf->setValue("astro/flag_stars", propMgr->get StelPropertyValue("StarMgr.flagStarsDisplayed").toBool()); conf->setValue("astro/flag_stars", propMgr->get StelPropertyValue("StarMgr.flagStarsDisplayed").toBool());
conf->setValue("astro/flag_star_name", propMgr->get StelPropertyValue("StarMgr.flagLabelsDisplayed").toBool()); conf->setValue("astro/flag_star_name", propMgr->get StelPropertyValue("StarMgr.flagLabelsDisplayed").toBool());
conf->setValue("stars/labels_amount", propMgr->get StelPropertyValue("StarMgr.labelsAmount").toDouble()); conf->setValue("stars/labels_amount", propMgr->get StelPropertyValue("StarMgr.labelsAmount").toDouble());
conf->setValue("astro/nebula_hints_amount", nmgr->getHin conf->setValue("astro/nebula_hints_amount", propMgr->get
tsAmount()); StelPropertyValue("NebulaMgr.hintsAmount").toDouble());
conf->setValue("astro/nebula_labels_amount", nmgr->getLab conf->setValue("astro/nebula_labels_amount", propMgr->get
elsAmount()); StelPropertyValue("NebulaMgr.labelsAmount").toDouble());
conf->setValue("astro/flag_nebula_hints_proportional", nmgr->getHin conf->setValue("astro/flag_nebula_hints_proportional", propMgr->get
tsProportional()); StelPropertyValue("NebulaMgr.hintsProportional").toBool());
conf->setValue("astro/flag_surface_brightness_usage", nmgr->getFla conf->setValue("astro/flag_surface_brightness_usage", propMgr->get
gSurfaceBrightnessUsage()); StelPropertyValue("NebulaMgr.flagSurfaceBrightnessUsage").toBool());
conf->setValue("gui/flag_dso_designation_usage", nmgr->getDes conf->setValue("astro/flag_surface_brightness_arcsec", propMgr->get
ignationUsage()); StelPropertyValue("NebulaMgr.flagSurfaceBrightnessArcsecUsage").toBool());
conf->setValue("astro/flag_nebula_name", nmgr->getFla conf->setValue("gui/flag_dso_designation_usage", propMgr->get
gHints()); StelPropertyValue("NebulaMgr.flagDesignationLabels").toBool());
conf->setValue("astro/flag_nebula_name", propMgr->get
StelPropertyValue("NebulaMgr.flagHintDisplayed").toBool());
conf->setValue("astro/flag_use_type_filter", propMgr->get
StelPropertyValue("NebulaMgr.flagTypeFiltersUsage").toBool());
conf->setValue("astro/flag_nebula_display_no_texture", !propMgr->ge tStelPropertyValue("StelSkyLayerMgr.flagShow").toBool() ); conf->setValue("astro/flag_nebula_display_no_texture", !propMgr->ge tStelPropertyValue("StelSkyLayerMgr.flagShow").toBool() );
conf->setValue("astro/flag_use_type_filter", nmgr->getFla gUseTypeFilters());
conf->setValue("projection/type", core->getCur rentProjectionTypeKey()); conf->setValue("projection/type", core->getCur rentProjectionTypeKey());
conf->setValue("astro/flag_nutation", core->getUse Nutation()); conf->setValue("astro/flag_nutation", core->getUse Nutation());
conf->setValue("astro/flag_topocentric_coordinates", core->getUse TopocentricCoordinates()); conf->setValue("astro/flag_topocentric_coordinates", core->getUse TopocentricCoordinates());
// view dialog / DSO tag settings // view dialog / DSO tag settings
const Nebula::CatalogGroup& cflags = nmgr->getCatalogFilters(); const Nebula::CatalogGroup& cflags = nmgr->getCatalogFilters();
conf->beginGroup("dso_catalog_filters"); conf->beginGroup("dso_catalog_filters");
conf->setValue("flag_show_ngc", (bool) (cflags & Nebula::CatNGC)); conf->setValue("flag_show_ngc", (bool) (cflags & Nebula::CatNGC));
conf->setValue("flag_show_ic", (bool) (cflags & Nebula::CatIC)); conf->setValue("flag_show_ic", (bool) (cflags & Nebula::CatIC));
skipping to change at line 705 skipping to change at line 747
conf->setValue("flag_show_vdb", (bool) (cflags & Nebula::CatVdB)); conf->setValue("flag_show_vdb", (bool) (cflags & Nebula::CatVdB));
conf->setValue("flag_show_sh2", (bool) (cflags & Nebula::CatSh2)); conf->setValue("flag_show_sh2", (bool) (cflags & Nebula::CatSh2));
conf->setValue("flag_show_rcw", (bool) (cflags & Nebula::CatRCW)); conf->setValue("flag_show_rcw", (bool) (cflags & Nebula::CatRCW));
conf->setValue("flag_show_lbn", (bool) (cflags & Nebula::CatLBN)); conf->setValue("flag_show_lbn", (bool) (cflags & Nebula::CatLBN));
conf->setValue("flag_show_ldn", (bool) (cflags & Nebula::CatLDN)); conf->setValue("flag_show_ldn", (bool) (cflags & Nebula::CatLDN));
conf->setValue("flag_show_cr", (bool) (cflags & Nebula::CatCr)); conf->setValue("flag_show_cr", (bool) (cflags & Nebula::CatCr));
conf->setValue("flag_show_mel", (bool) (cflags & Nebula::CatMel)); conf->setValue("flag_show_mel", (bool) (cflags & Nebula::CatMel));
conf->setValue("flag_show_ced", (bool) (cflags & Nebula::CatCed)); conf->setValue("flag_show_ced", (bool) (cflags & Nebula::CatCed));
conf->setValue("flag_show_pgc", (bool) (cflags & Nebula::CatPGC)); conf->setValue("flag_show_pgc", (bool) (cflags & Nebula::CatPGC));
conf->setValue("flag_show_ugc", (bool) (cflags & Nebula::CatUGC)); conf->setValue("flag_show_ugc", (bool) (cflags & Nebula::CatUGC));
conf->setValue("flag_show_arp", (bool) (cflags & Nebula::CatArp));
conf->setValue("flag_show_vv", (bool) (cflags & Nebula::CatVV));
conf->setValue("flag_show_pk", (bool) (cflags & Nebula::CatPK));
conf->endGroup(); conf->endGroup();
const Nebula::TypeGroup& tflags = nmgr->getTypeFilters(); const Nebula::TypeGroup& tflags = nmgr->getTypeFilters();
conf->beginGroup("dso_type_filters"); conf->beginGroup("dso_type_filters");
conf->setValue("flag_show_galaxies", (bool) (tflags & Ne bula::TypeGalaxies)); conf->setValue("flag_show_galaxies", (bool) (tflags & Ne bula::TypeGalaxies));
conf->setValue("flag_show_active_galaxies", (bool) (tflags & Ne bula::TypeActiveGalaxies)); conf->setValue("flag_show_active_galaxies", (bool) (tflags & Ne bula::TypeActiveGalaxies));
conf->setValue("flag_show_interacting_galaxies", (bool) (tflags & Ne bula::TypeInteractingGalaxies)); conf->setValue("flag_show_interacting_galaxies", (bool) (tflags & Ne bula::TypeInteractingGalaxies));
conf->setValue("flag_show_clusters", (bool) (tflags & Ne bula::TypeStarClusters)); conf->setValue("flag_show_clusters", (bool) (tflags & Ne bula::TypeStarClusters));
conf->setValue("flag_show_bright_nebulae", (bool) (tflags & Ne bula::TypeBrightNebulae)); conf->setValue("flag_show_bright_nebulae", (bool) (tflags & Ne bula::TypeBrightNebulae));
conf->setValue("flag_show_dark_nebulae", (bool) (tflags & Ne bula::TypeDarkNebulae)); conf->setValue("flag_show_dark_nebulae", (bool) (tflags & Ne bula::TypeDarkNebulae));
skipping to change at line 806 skipping to change at line 851
(bool) (flags & StelObject::SiderealTime)); (bool) (flags & StelObject::SiderealTime));
conf->endGroup(); conf->endGroup();
} }
// toolbar auto-hide status // toolbar auto-hide status
conf->setValue("gui/auto_hide_horizontal_toolbar", gui->getAutoHideH orizontalButtonBar()); conf->setValue("gui/auto_hide_horizontal_toolbar", gui->getAutoHideH orizontalButtonBar());
conf->setValue("gui/auto_hide_vertical_toolbar", gui->getAutoHideVer ticalButtonBar()); conf->setValue("gui/auto_hide_vertical_toolbar", gui->getAutoHideVer ticalButtonBar());
conf->setValue("gui/flag_show_nebulae_background_button", gui->getFl agShowNebulaBackgroundButton()); conf->setValue("gui/flag_show_nebulae_background_button", gui->getFl agShowNebulaBackgroundButton());
conf->setValue("gui/flag_show_toast_survey_button", gui->getFlagShow ToastSurveyButton()); conf->setValue("gui/flag_show_toast_survey_button", gui->getFlagShow ToastSurveyButton());
conf->setValue("gui/flag_show_bookmarks_button", gui->getFlagShowBoo kmarksButton()); conf->setValue("gui/flag_show_bookmarks_button", gui->getFlagShowBoo kmarksButton());
conf->setValue("gui/flag_show_icrs_grid_button", gui->getFlagShowICR
SGridButton());
conf->setValue("gui/flag_show_galactic_grid_button", gui->getFlagSho
wGalacticGridButton());
conf->setValue("gui/flag_show_ecliptic_grid_button", gui->getFlagSho
wEclipticGridButton());
conf->setValue("gui/flag_show_boundaries_button", gui->getFlagShowCo
nstellationBoundariesButton());
conf->setValue("gui/flag_show_decimal_degrees", StelApp::getInstance ().getFlagShowDecimalDegrees()); conf->setValue("gui/flag_show_decimal_degrees", StelApp::getInstance ().getFlagShowDecimalDegrees());
conf->setValue("gui/flag_use_azimuth_from_south", StelApp::getInstan ce().getFlagSouthAzimuthUsage()); conf->setValue("gui/flag_use_azimuth_from_south", StelApp::getInstan ce().getFlagSouthAzimuthUsage());
conf->setValue("gui/flag_time_jd", gui->getButtonBar()->getFlagTimeJ d()); conf->setValue("gui/flag_time_jd", gui->getButtonBar()->getFlagTimeJ d());
conf->setValue("gui/flag_show_buttons_background", StelMainView::get
Instance().getFlagUseButtonsBackground());
conf->setValue("gui/flag_indication_mount_mode", mvmgr->getFlagIndic
ationMountMode());
// configuration dialog / navigation tab // configuration dialog / navigation tab
conf->setValue("navigation/flag_enable_zoom_keys", mvmgr->getFlagEna bleZoomKeys()); conf->setValue("navigation/flag_enable_zoom_keys", mvmgr->getFlagEna bleZoomKeys());
conf->setValue("navigation/flag_enable_mouse_navigation", mvmgr->get FlagEnableMouseNavigation()); conf->setValue("navigation/flag_enable_mouse_navigation", mvmgr->get FlagEnableMouseNavigation());
conf->setValue("navigation/flag_enable_move_keys", mvmgr->getFlagEna bleMoveKeys()); conf->setValue("navigation/flag_enable_move_keys", mvmgr->getFlagEna bleMoveKeys());
conf->setValue("navigation/startup_time_mode", core->getStartupTimeM ode()); conf->setValue("navigation/startup_time_mode", core->getStartupTimeM ode());
conf->setValue("navigation/today_time", core->getInitTodayTime()); conf->setValue("navigation/today_time", core->getInitTodayTime());
conf->setValue("navigation/preset_sky_time", core->getPresetSkyTime( )); conf->setValue("navigation/preset_sky_time", core->getPresetSkyTime( ));
conf->setValue("navigation/time_correction_algorithm", core->getCurr entDeltaTAlgorithmKey()); conf->setValue("navigation/time_correction_algorithm", core->getCurr entDeltaTAlgorithmKey());
conf->setValue("navigation/init_fov", mvmgr->getInitFov()); conf->setValue("navigation/init_fov", mvmgr->getInitFov());
skipping to change at line 945 skipping to change at line 996
html += "<p>" + q_(d) + "</p>"; html += "<p>" + q_(d) + "</p>";
html += "<p><strong>" + q_("Authors") + "</strong>: " + desc.info.authors; html += "<p><strong>" + q_("Authors") + "</strong>: " + desc.info.authors;
html += "<br /><strong>" + q_("Contact") + "</strong >: " + desc.info.contact; html += "<br /><strong>" + q_("Contact") + "</strong >: " + desc.info.contact;
if (!desc.info.version.isEmpty()) if (!desc.info.version.isEmpty())
html += "<br /><strong>" + q_("Version") + " </strong>: " + desc.info.version; html += "<br /><strong>" + q_("Version") + " </strong>: " + desc.info.version;
html += "</p></body></html>"; html += "</p></body></html>";
ui->pluginsInfoBrowser->document()->setDefaultStyleS heet(QString(gui->getStelStyle().htmlStyleSheet)); ui->pluginsInfoBrowser->document()->setDefaultStyleS heet(QString(gui->getStelStyle().htmlStyleSheet));
ui->pluginsInfoBrowser->setHtml(html); ui->pluginsInfoBrowser->setHtml(html);
ui->pluginLoadAtStartupCheckBox->setChecked(desc.loa dAtStartup); ui->pluginLoadAtStartupCheckBox->setChecked(desc.loa dAtStartup);
StelModule* pmod = StelApp::getInstance().getModuleM gr().getModule(desc.info.id, true); StelModule* pmod = StelApp::getInstance().getModuleM gr().getModule(desc.info.id, true);
if (pmod != NULL) if (pmod != Q_NULLPTR)
ui->pluginConfigureButton->setEnabled(pmod-> configureGui(false)); ui->pluginConfigureButton->setEnabled(pmod-> configureGui(false));
else else
ui->pluginConfigureButton->setEnabled(false) ; ui->pluginConfigureButton->setEnabled(false) ;
return; return;
} }
} }
} }
void ConfigurationDialog::pluginConfigureCurrentSelection() void ConfigurationDialog::pluginConfigureCurrentSelection()
{ {
skipping to change at line 967 skipping to change at line 1018
if (id.isEmpty()) if (id.isEmpty())
return; return;
StelModuleMgr& moduleMgr = StelApp::getInstance().getModuleMgr(); StelModuleMgr& moduleMgr = StelApp::getInstance().getModuleMgr();
const QList<StelModuleMgr::PluginDescriptor> pluginsList = moduleMgr .getPluginsList(); const QList<StelModuleMgr::PluginDescriptor> pluginsList = moduleMgr .getPluginsList();
foreach (const StelModuleMgr::PluginDescriptor& desc, pluginsList) foreach (const StelModuleMgr::PluginDescriptor& desc, pluginsList)
{ {
if (id == desc.info.id) if (id == desc.info.id)
{ {
StelModule* pmod = moduleMgr.getModule(desc.info.id, QObject::sender()->objectName()=="pluginsListWidget"); StelModule* pmod = moduleMgr.getModule(desc.info.id, QObject::sender()->objectName()=="pluginsListWidget");
if (pmod != NULL) if (pmod != Q_NULLPTR)
{ {
pmod->configureGui(true); pmod->configureGui(true);
} }
return; return;
} }
} }
} }
void ConfigurationDialog::loadAtStartupChanged(int state) void ConfigurationDialog::loadAtStartupChanged(int state)
{ {
skipping to change at line 1161 skipping to change at line 1212
int size = starCatalogDownloadReply->bytesAvailable(); int size = starCatalogDownloadReply->bytesAvailable();
progressBar->setValue((float)progressBar->getValue()+(float)size/102 4); progressBar->setValue((float)progressBar->getValue()+(float)size/102 4);
currentDownloadFile->write(starCatalogDownloadReply->read(size)); currentDownloadFile->write(starCatalogDownloadReply->read(size));
} }
void ConfigurationDialog::downloadStars() void ConfigurationDialog::downloadStars()
{ {
Q_ASSERT(!nextStarCatalogToDownload.isEmpty()); Q_ASSERT(!nextStarCatalogToDownload.isEmpty());
Q_ASSERT(!isDownloadingStarCatalog); Q_ASSERT(!isDownloadingStarCatalog);
Q_ASSERT(starCatalogDownloadReply==NULL); Q_ASSERT(starCatalogDownloadReply==Q_NULLPTR);
Q_ASSERT(currentDownloadFile==NULL); Q_ASSERT(currentDownloadFile==Q_NULLPTR);
Q_ASSERT(progressBar==NULL); Q_ASSERT(progressBar==Q_NULLPTR);
QString path = StelFileMgr::getUserDir()+QString("/stars/default/")+ nextStarCatalogToDownload.value("fileName").toString(); QString path = StelFileMgr::getUserDir()+QString("/stars/default/")+ nextStarCatalogToDownload.value("fileName").toString();
currentDownloadFile = new QFile(path); currentDownloadFile = new QFile(path);
if (!currentDownloadFile->open(QIODevice::WriteOnly)) if (!currentDownloadFile->open(QIODevice::WriteOnly))
{ {
qWarning() << "Can't open a writable file for storing new st ar catalog: " << QDir::toNativeSeparators(path); qWarning() << "Can't open a writable file for storing new st ar catalog: " << QDir::toNativeSeparators(path);
currentDownloadFile->deleteLater(); currentDownloadFile->deleteLater();
currentDownloadFile = NULL; currentDownloadFile = Q_NULLPTR;
ui->downloadLabel->setText(q_("Error downloading %1:\n%2").a rg(nextStarCatalogToDownload.value("id").toString()).arg(QString("Can't ope n a writable file for storing new star catalog: %1").arg(path))); ui->downloadLabel->setText(q_("Error downloading %1:\n%2").a rg(nextStarCatalogToDownload.value("id").toString()).arg(QString("Can't ope n a writable file for storing new star catalog: %1").arg(path)));
ui->downloadRetryButton->setVisible(true); ui->downloadRetryButton->setVisible(true);
return; return;
} }
isDownloadingStarCatalog = true; isDownloadingStarCatalog = true;
updateStarCatalogControlsText(); updateStarCatalogControlsText();
ui->downloadCancelButton->setVisible(true); ui->downloadCancelButton->setVisible(true);
ui->downloadRetryButton->setVisible(false); ui->downloadRetryButton->setVisible(false);
ui->getStarsButton->setVisible(true); ui->getStarsButton->setVisible(true);
skipping to change at line 1224 skipping to change at line 1275
void ConfigurationDialog::downloadFinished() void ConfigurationDialog::downloadFinished()
{ {
Q_ASSERT(currentDownloadFile); Q_ASSERT(currentDownloadFile);
Q_ASSERT(starCatalogDownloadReply); Q_ASSERT(starCatalogDownloadReply);
Q_ASSERT(progressBar); Q_ASSERT(progressBar);
if (starCatalogDownloadReply->error()!=QNetworkReply::NoError) if (starCatalogDownloadReply->error()!=QNetworkReply::NoError)
{ {
starCatalogDownloadReply->deleteLater(); starCatalogDownloadReply->deleteLater();
starCatalogDownloadReply = NULL; starCatalogDownloadReply = Q_NULLPTR;
currentDownloadFile->close(); currentDownloadFile->close();
currentDownloadFile->deleteLater(); currentDownloadFile->deleteLater();
currentDownloadFile = NULL; currentDownloadFile = Q_NULLPTR;
StelApp::getInstance().removeProgressBar(progressBar); StelApp::getInstance().removeProgressBar(progressBar);
progressBar=NULL; progressBar=Q_NULLPTR;
return; return;
} }
const QVariant& redirect = starCatalogDownloadReply->attribute(QNetw orkRequest::RedirectionTargetAttribute); const QVariant& redirect = starCatalogDownloadReply->attribute(QNetw orkRequest::RedirectionTargetAttribute);
if (!redirect.isNull()) if (!redirect.isNull())
{ {
// We got a redirection, we need to follow // We got a redirection, we need to follow
starCatalogDownloadReply->deleteLater(); starCatalogDownloadReply->deleteLater();
QNetworkRequest req(redirect.toUrl()); QNetworkRequest req(redirect.toUrl());
req.setAttribute(QNetworkRequest::CacheSaveControlAttribute, false); req.setAttribute(QNetworkRequest::CacheSaveControlAttribute, false);
skipping to change at line 1255 skipping to change at line 1306
connect(starCatalogDownloadReply, SIGNAL(finished()), this, SLOT(downloadFinished())); connect(starCatalogDownloadReply, SIGNAL(finished()), this, SLOT(downloadFinished()));
connect(starCatalogDownloadReply, SIGNAL(error(QNetworkReply ::NetworkError)), this, SLOT(downloadError(QNetworkReply::NetworkError))); connect(starCatalogDownloadReply, SIGNAL(error(QNetworkReply ::NetworkError)), this, SLOT(downloadError(QNetworkReply::NetworkError)));
return; return;
} }
Q_ASSERT(starCatalogDownloadReply->bytesAvailable()==0); Q_ASSERT(starCatalogDownloadReply->bytesAvailable()==0);
isDownloadingStarCatalog = false; isDownloadingStarCatalog = false;
currentDownloadFile->close(); currentDownloadFile->close();
currentDownloadFile->deleteLater(); currentDownloadFile->deleteLater();
currentDownloadFile = NULL; currentDownloadFile = Q_NULLPTR;
starCatalogDownloadReply->deleteLater(); starCatalogDownloadReply->deleteLater();
starCatalogDownloadReply = NULL; starCatalogDownloadReply = Q_NULLPTR;
StelApp::getInstance().removeProgressBar(progressBar); StelApp::getInstance().removeProgressBar(progressBar);
progressBar=NULL; progressBar=Q_NULLPTR;
ui->downloadLabel->setText(q_("Verifying file integrity...")); ui->downloadLabel->setText(q_("Verifying file integrity..."));
if (GETSTELMODULE(StarMgr)->checkAndLoadCatalog(nextStarCatalogToDow nload)==false) if (GETSTELMODULE(StarMgr)->checkAndLoadCatalog(nextStarCatalogToDow nload)==false)
{ {
ui->getStarsButton->setVisible(false); ui->getStarsButton->setVisible(false);
ui->downloadLabel->setText(q_("Error downloading %1:\nFile i s corrupted.").arg(nextStarCatalogToDownload.value("id").toString())); ui->downloadLabel->setText(q_("Error downloading %1:\nFile i s corrupted.").arg(nextStarCatalogToDownload.value("id").toString()));
ui->downloadCancelButton->setVisible(false); ui->downloadCancelButton->setVisible(false);
ui->downloadRetryButton->setVisible(true); ui->downloadRetryButton->setVisible(true);
} }
else else
skipping to change at line 1468 skipping to change at line 1519
} }
void ConfigurationDialog::setDeltaTAlgorithmDescription() void ConfigurationDialog::setDeltaTAlgorithmDescription()
{ {
ui->deltaTAlgorithmDescription->document()->setDefaultStyleSheet(QSt ring(gui->getStelStyle().htmlStyleSheet)); ui->deltaTAlgorithmDescription->document()->setDefaultStyleSheet(QSt ring(gui->getStelStyle().htmlStyleSheet));
ui->deltaTAlgorithmDescription->setHtml(StelApp::getInstance().getCo re()->getCurrentDeltaTAlgorithmDescription()); ui->deltaTAlgorithmDescription->setHtml(StelApp::getInstance().getCo re()->getCurrentDeltaTAlgorithmDescription());
} }
void ConfigurationDialog::showCustomDeltaTEquationDialog() void ConfigurationDialog::showCustomDeltaTEquationDialog()
{ {
if (customDeltaTEquationDialog == NULL) if (customDeltaTEquationDialog == Q_NULLPTR)
customDeltaTEquationDialog = new CustomDeltaTEquationDialog( ); customDeltaTEquationDialog = new CustomDeltaTEquationDialog( );
customDeltaTEquationDialog->setVisible(true); customDeltaTEquationDialog->setVisible(true);
} }
void ConfigurationDialog::populateDateFormatsList() void ConfigurationDialog::populateDateFormatsList()
{ {
Q_ASSERT(ui->dateFormatsComboBox); Q_ASSERT(ui->dateFormatsComboBox);
QComboBox* dfmts = ui->dateFormatsComboBox; QComboBox* dfmts = ui->dateFormatsComboBox;
 End of changes. 33 change blocks. 
37 lines changed or deleted 117 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/