MeteorShowersMgr.cpp   MeteorShowersMgr.cpp 
skipping to change at line 36 skipping to change at line 36
#include "MSConfigDialog.hpp" #include "MSConfigDialog.hpp"
#include "MSSearchDialog.hpp" #include "MSSearchDialog.hpp"
#include "MeteorShowersMgr.hpp" #include "MeteorShowersMgr.hpp"
#include "Planet.hpp" #include "Planet.hpp"
#include "StelActionMgr.hpp" #include "StelActionMgr.hpp"
#include "StelApp.hpp" #include "StelApp.hpp"
#include "StelFileMgr.hpp" #include "StelFileMgr.hpp"
#include "StelGui.hpp" #include "StelGui.hpp"
#include "StelModuleMgr.hpp" #include "StelModuleMgr.hpp"
#include "StelProgressController.hpp" #include "StelProgressController.hpp"
#include "StelTextureMgr.hpp"
#include "StelUtils.hpp" #include "StelUtils.hpp"
#include "SporadicMeteorMgr.hpp" #include "SporadicMeteorMgr.hpp"
MeteorShowersMgr::MeteorShowersMgr() MeteorShowersMgr::MeteorShowersMgr()
: m_meteorShowers(NULL) : m_meteorShowers(NULL)
, m_configDialog(NULL) , m_configDialog(NULL)
, m_searchDialog(NULL) , m_searchDialog(NULL)
, m_conf(StelApp::getInstance().getSettings()) , m_conf(StelApp::getInstance().getSettings())
, m_onEarth(false) , m_onEarth(false)
, m_enablePlugin(false) , m_enablePlugin(false)
skipping to change at line 62 skipping to change at line 61
, m_showSearchButton(true) , m_showSearchButton(true)
, m_messageTimer(NULL) , m_messageTimer(NULL)
, m_isUpdating(false) , m_isUpdating(false)
, m_enableAutoUpdates(true) , m_enableAutoUpdates(true)
, m_updateFrequencyHours(0) , m_updateFrequencyHours(0)
, m_statusOfLastUpdate(OUTDATED) , m_statusOfLastUpdate(OUTDATED)
, m_downloadMgr(NULL) , m_downloadMgr(NULL)
, m_progressBar(NULL) , m_progressBar(NULL)
{ {
setObjectName("MeteorShowers"); setObjectName("MeteorShowers");
qsrand(QDateTime::currentMSecsSinceEpoch());
} }
MeteorShowersMgr::~MeteorShowersMgr() MeteorShowersMgr::~MeteorShowersMgr()
{ {
delete m_configDialog; delete m_configDialog;
delete m_searchDialog; delete m_searchDialog;
delete m_downloadMgr; delete m_downloadMgr;
} }
void MeteorShowersMgr::init() void MeteorShowersMgr::init()
skipping to change at line 448 skipping to change at line 446
qWarning() << "MeteorShowersMgr : unable to create toolbar b uttons for MeteorShowers plugin!" qWarning() << "MeteorShowersMgr : unable to create toolbar b uttons for MeteorShowers plugin!"
<< e.what(); << e.what();
} }
m_showSearchButton = show; m_showSearchButton = show;
m_conf->setValue(MS_CONFIG_PREFIX + "/show_search_button", show); m_conf->setValue(MS_CONFIG_PREFIX + "/show_search_button", show);
} }
void MeteorShowersMgr::setColorARG(const Vec3f& rgb) void MeteorShowersMgr::setColorARG(const Vec3f& rgb)
{ {
m_colorARG = rgb; m_colorARG = rgb;
QString rgbStr = QString("%1,%2,%3").arg(rgb[0]).arg(rgb[1]).arg(rgb m_conf->setValue(MS_CONFIG_PREFIX + "/colorARG", StelUtils::vec3fToS
[2]); tr(rgb));
m_conf->setValue(MS_CONFIG_PREFIX + "/colorARG", rgbStr);
} }
void MeteorShowersMgr::setColorARC(const Vec3f& rgb) void MeteorShowersMgr::setColorARC(const Vec3f& rgb)
{ {
m_colorARC = rgb; m_colorARC = rgb;
QString rgbStr = QString("%1,%2,%3").arg(rgb[0]).arg(rgb[1]).arg(rgb m_conf->setValue(MS_CONFIG_PREFIX + "/colorARC", StelUtils::vec3fToS
[2]); tr(rgb));
m_conf->setValue(MS_CONFIG_PREFIX + "/colorARC", rgbStr);
} }
void MeteorShowersMgr::setColorIR(const Vec3f& rgb) void MeteorShowersMgr::setColorIR(const Vec3f& rgb)
{ {
m_colorIR = rgb; m_colorIR = rgb;
QString rgbStr = QString("%1,%2,%3").arg(rgb[0]).arg(rgb[1]).arg(rgb m_conf->setValue(MS_CONFIG_PREFIX + "/colorIR", StelUtils::vec3fToSt
[2]); r(rgb));
m_conf->setValue(MS_CONFIG_PREFIX + "/colorIR", rgbStr);
} }
void MeteorShowersMgr::setEnableAtStartup(const bool& b) void MeteorShowersMgr::setEnableAtStartup(const bool& b)
{ {
m_enableAtStartup = b; m_enableAtStartup = b;
m_conf->setValue(MS_CONFIG_PREFIX + "/enable_at_startup", b); m_conf->setValue(MS_CONFIG_PREFIX + "/enable_at_startup", b);
} }
void MeteorShowersMgr::setFontSize(int pixelSize) void MeteorShowersMgr::setFontSize(int pixelSize)
{ {
pixelSize = pixelSize < 1 ? 13 : pixelSize; pixelSize = pixelSize < 1 ? 13 : pixelSize;
m_font.setPixelSize(pixelSize); m_font.setPixelSize(pixelSize);
m_conf->setValue(MS_CONFIG_PREFIX + "/font_size", pixelSize); m_conf->setValue(MS_CONFIG_PREFIX + "/font_size", pixelSize);
} }
void MeteorShowersMgr::setEnableLabels(const bool& b) void MeteorShowersMgr::setEnableLabels(const bool& b)
{ {
m_enableLabels = b; if (m_enableLabels != b)
m_conf->setValue(MS_CONFIG_PREFIX + "/flag_radiant_labels", b); {
m_enableLabels = b;
m_conf->setValue(MS_CONFIG_PREFIX + "/flag_radiant_labels",
b);
emit enableLabelsChanged(b);
}
} }
void MeteorShowersMgr::setEnableMarker(const bool& b) void MeteorShowersMgr::setEnableMarker(const bool& b)
{ {
m_enableMarker = b; m_enableMarker = b;
m_conf->setValue(MS_CONFIG_PREFIX + "/flag_radiant_marker", b); m_conf->setValue(MS_CONFIG_PREFIX + "/flag_radiant_marker", b);
} }
void MeteorShowersMgr::setUpdateFrequencyHours(const int& hours) void MeteorShowersMgr::setUpdateFrequencyHours(const int& hours)
{ {
 End of changes. 6 change blocks. 
13 lines changed or deleted 13 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/