Novae.hpp   Novae.hpp 
skipping to change at line 26 skipping to change at line 26
* Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA. * Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA.
*/ */
#ifndef _NOVAE_HPP_ #ifndef _NOVAE_HPP_
#define _NOVAE_HPP_ #define _NOVAE_HPP_
#include "StelObjectModule.hpp" #include "StelObjectModule.hpp"
#include "StelObject.hpp" #include "StelObject.hpp"
#include "StelFader.hpp" #include "StelFader.hpp"
#include "Nova.hpp" #include "Nova.hpp"
#include "StelTextureTypes.hpp"
#include <QFont> #include <QFont>
#include <QVariantMap> #include <QVariantMap>
#include <QDateTime> #include <QDateTime>
#include <QList> #include <QList>
#include <QSharedPointer> #include <QSharedPointer>
#include <QHash> #include <QHash>
class QNetworkAccessManager; class QNetworkAccessManager;
class QNetworkReply; class QNetworkReply;
class QProgressBar; class QProgressBar;
class QSettings; class QSettings;
class QTimer; class QTimer;
class NovaeDialog; class NovaeDialog;
class StelPainter;
typedef QSharedPointer<Nova> NovaP; typedef QSharedPointer<Nova> NovaP;
/*! @mainpage notitle /*! @mainpage notitle
@section overview Plugin Overview @section overview Plugin Overview
The %Bright Novae plugin displays the positions some bright The %Bright Novae plugin displays the positions some bright
novae in the Milky Way galaxy. novae in the Milky Way galaxy.
@section ncat Bright Novae Catalog @section ncat Bright Novae Catalog
skipping to change at line 81 skipping to change at line 83
DownloadError, //!< Error during download phase DownloadError, //!< Error during download phase
OtherError //!< Other error OtherError //!< Other error
}; };
Novae(); Novae();
virtual ~Novae(); virtual ~Novae();
//////////////////////////////////////////////////////////////////// /////// //////////////////////////////////////////////////////////////////// ///////
// Methods defined in the StelModule class // Methods defined in the StelModule class
virtual void init(); virtual void init();
virtual void deinit();
virtual void update(double) {;} virtual void update(double) {;}
virtual void draw(StelCore* core, class StelRenderer* renderer); virtual void draw(StelCore* core);
virtual void drawPointer(StelCore* core, class StelRenderer* rendere virtual void drawPointer(StelCore* core, StelPainter& painter);
r, StelProjectorP projector);
virtual double getCallOrder(StelModuleActionName actionName) const; virtual double getCallOrder(StelModuleActionName actionName) const;
//////////////////////////////////////////////////////////////////// /////// //////////////////////////////////////////////////////////////////// ///////
// Methods defined in StelObjectManager class // Methods defined in StelObjectManager class
//! Used to get a list of objects which are near to some position. //! Used to get a list of objects which are near to some position.
//! @param v a vector representing the position in th sky around whi ch to search for nebulae. //! @param v a vector representing the position in th sky around whi ch to search for nebulae.
//! @param limitFov the field of view around the position v in which to search for satellites. //! @param limitFov the field of view around the position v in which to search for satellites.
//! @param core the StelCore to use for computations. //! @param core the StelCore to use for computations.
//! @return an list containing the satellites located inside the lim itFov circle around position v. //! @return an list containing the satellites located inside the lim itFov circle around position v.
virtual QList<StelObjectP> searchAround(const Vec3d& v, double limit Fov, const StelCore* core) const; virtual QList<StelObjectP> searchAround(const Vec3d& v, double limit Fov, const StelCore* core) const;
skipping to change at line 158 skipping to change at line 159
//! Get the update frequency in days //! Get the update frequency in days
int getUpdateFrequencyDays(void) {return updateFrequencyDays;} int getUpdateFrequencyDays(void) {return updateFrequencyDays;}
void setUpdateFrequencyDays(int days) {updateFrequencyDays = days;} void setUpdateFrequencyDays(int days) {updateFrequencyDays = days;}
//! Get the number of seconds till the next update //! Get the number of seconds till the next update
int getSecondsToUpdate(void); int getSecondsToUpdate(void);
//! Get the current updateState //! Get the current updateState
UpdateState getUpdateState(void) {return updateState;} UpdateState getUpdateState(void) {return updateState;}
//! Get list of novae
QString getNovaeList();
//! Get lower limit of brightness for displayed novae
float getLowerLimitBrightness();
//! Get count of novae from catalog
int getCountNovae(void) {return NovaCnt;}
signals: signals:
//! @param state the new update state. //! @param state the new update state.
void updateStateChanged(Novae::UpdateState state); void updateStateChanged(Novae::UpdateState state);
//! Emitted after a JSON update has run. //! Emitted after a JSON update has run.
void jsonUpdateComplete(void); void jsonUpdateComplete(void);
public slots: public slots:
// FIXME: Add functions for scripting support // FIXME: Add functions for scripting support
skipping to change at line 180 skipping to change at line 190
void updateJSON(void); void updateJSON(void);
//! Display a message. This is used for plugin-specific warnings and such //! Display a message. This is used for plugin-specific warnings and such
void displayMessage(const QString& message, const QString hexColor=" #999999"); void displayMessage(const QString& message, const QString hexColor=" #999999");
void messageTimeout(void); void messageTimeout(void);
private: private:
// Font used for displaying our text // Font used for displaying our text
QFont font; QFont font;
// if existing, delete Satellites section in main config.ini, then c reate with default values // if existing, delete Novae section in main config.ini, then create with default values
void restoreDefaultConfigIni(void); void restoreDefaultConfigIni(void);
//! Replace the JSON file with the default from the compiled-in reso urce //! Replace the JSON file with the default from the compiled-in reso urce
void restoreDefaultJsonFile(void); void restoreDefaultJsonFile(void);
//! Read the JSON file and create list of novae. //! Read the JSON file and create list of novae.
void readJsonFile(void); void readJsonFile(void);
//! Creates a backup of the novae.json file called novae.json.old //! Creates a backup of the novae.json file called novae.json.old
//! @param deleteOriginal if true, the original file is removed, els e not //! @param deleteOriginal if true, the original file is removed, els e not
skipping to change at line 210 skipping to change at line 220
bool checkJsonFileFormat(void); bool checkJsonFileFormat(void);
//! Parse JSON file and load novae to map //! Parse JSON file and load novae to map
QVariantMap loadNovaeMap(QString path=QString()); QVariantMap loadNovaeMap(QString path=QString());
//! Set items for list of struct from data map //! Set items for list of struct from data map
void setNovaeMap(const QVariantMap& map); void setNovaeMap(const QVariantMap& map);
QString novaeJsonPath; QString novaeJsonPath;
class StelTextureNew* texPointer; int NovaCnt;
StelTextureSP texPointer;
QList<NovaP> nova; QList<NovaP> nova;
QHash<QString, double> novalist; QHash<QString, double> novalist;
// variables and functions for the updater // variables and functions for the updater
UpdateState updateState; UpdateState updateState;
QNetworkAccessManager* downloadMgr; QNetworkAccessManager* downloadMgr;
QString updateUrl; QString updateUrl;
QProgressBar* progressBar; class StelProgressController* progressBar;
QTimer* updateTimer; QTimer* updateTimer;
QTimer* messageTimer; QTimer* messageTimer;
QList<int> messageIDs; QList<int> messageIDs;
bool updatesEnabled; bool updatesEnabled;
QDateTime lastUpdate; QDateTime lastUpdate;
int updateFrequencyDays; int updateFrequencyDays;
QSettings* conf; QSettings* conf;
// GUI // GUI
skipping to change at line 240 skipping to change at line 252
private slots: private slots:
//! Check to see if an update is required. This is called periodica lly by a timer //! Check to see if an update is required. This is called periodica lly by a timer
//! if the last update was longer than updateFrequencyHours ago then the update is //! if the last update was longer than updateFrequencyHours ago then the update is
//! done. //! done.
void checkForUpdate(void); void checkForUpdate(void);
void updateDownloadComplete(QNetworkReply* reply); void updateDownloadComplete(QNetworkReply* reply);
}; };
#include "fixx11h.h"
#include <QObject> #include <QObject>
#include "StelPluginInterface.hpp" #include "StelPluginInterface.hpp"
//! This class is used by Qt to manage a plug-in interface //! This class is used by Qt to manage a plug-in interface
class NovaeStelPluginInterface : public QObject, public StelPluginInterface class NovaeStelPluginInterface : public QObject, public StelPluginInterface
{ {
Q_OBJECT Q_OBJECT
Q_PLUGIN_METADATA(IID "stellarium.StelGuiPluginInterface/1.0")
Q_INTERFACES(StelPluginInterface) Q_INTERFACES(StelPluginInterface)
public: public:
virtual StelModule* getStelModule() const; virtual StelModule* getStelModule() const;
virtual StelPluginInfo getPluginInfo() const; virtual StelPluginInfo getPluginInfo() const;
}; };
#endif /*_NOVAE_HPP_*/ #endif /*_NOVAE_HPP_*/
 End of changes. 10 change blocks. 
8 lines changed or deleted 19 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/