MainService.hpp   MainService.hpp 
skipping to change at line 39 skipping to change at line 39
#include <QJsonObject> #include <QJsonObject>
#include <QMutex> #include <QMutex>
class StelCore; class StelCore;
class StelActionMgr; class StelActionMgr;
class LandscapeMgr; class LandscapeMgr;
class StelLocaleMgr; class StelLocaleMgr;
class StelMovementMgr; class StelMovementMgr;
class StelObjectMgr; class StelObjectMgr;
class StelPropertyMgr; class StelPropertyMgr;
class StelProperty;
class StelScriptMgr; class StelScriptMgr;
class StelSkyCultureMgr; class StelSkyCultureMgr;
//! @ingroup remoteControl //! @ingroup remoteControl
//! Implements the main API services, including the \c status operation whi ch can be repeatedly polled to find the current state of the main program, //! Implements the main API services, including the \c status operation whi ch can be repeatedly polled to find the current state of the main program,
//! including time, view, location, StelAction and StelProperty state chang es, movement, script status ... //! including time, view, location, StelAction and StelProperty state chang es, movement, script status ...
//! //!
//! @see @ref rcMainService //! @see @ref rcMainService
class MainService : public AbstractAPIService class MainService : public AbstractAPIService
{ {
Q_OBJECT Q_OBJECT
Q_ENUMS(SelectionMode)
public: public:
MainService(const QByteArray& serviceName, QObject* parent = 0); enum SelectionMode
{
Center,
Zoom,
Mark
};
virtual ~MainService() {} MainService(QObject* parent = Q_NULLPTR);
//! Used to implement move functionality //! Used to implement move functionality
virtual void update(double deltaTime) Q_DECL_OVERRIDE; virtual void update(double deltaTime) Q_DECL_OVERRIDE;
virtual QLatin1String getPath() const Q_DECL_OVERRIDE { return QLati
protected: n1String("main"); }
//! @brief Implements the GET operations //! @brief Implements the GET operations
//! @see @ref rcMainServiceGET //! @see @ref rcMainServiceGET
virtual void getImpl(const QByteArray& operation,const APIParameters &parameters, APIServiceResponse& response) Q_DECL_OVERRIDE; virtual void get(const QByteArray& operation,const APIParameters &pa rameters, APIServiceResponse& response) Q_DECL_OVERRIDE;
//! @brief Implements the HTTP POST operations //! @brief Implements the HTTP POST operations
//! @see @ref rcMainServicePOST //! @see @ref rcMainServicePOST
virtual void postImpl(const QByteArray &operation, const APIParamete rs &parameters, const QByteArray &data, APIServiceResponse &response) Q_DEC L_OVERRIDE; virtual void post(const QByteArray &operation, const APIParameters & parameters, const QByteArray &data, APIServiceResponse &response) Q_DECL_OV ERRIDE;
private slots: private slots:
StelObjectP getSelectedObject(); StelObjectP getSelectedObject();
//! Returns the info string of the currently selected object //! Returns the info string of the currently selected object
QString getInfoString(); QString getInfoString();
//! Like StelDialog::gotoObject //! Like StelDialog::gotoObject
bool focusObject(const QString& name); bool focusObject(const QString& name, SelectionMode mode);
void focusPosition(const Vec3d& pos); void focusPosition(const Vec3d& pos);
void updateMovement(float x, float y, bool xUpdated, bool yUpdated); void updateMovement(double x, double y, bool xUpdated, bool yUpdated );
// Allow azimut/altitude changes. Values must be in Radians. // Allow azimut/altitude changes. Values must be in Radians.
void updateView(double az, double alt, bool azUpdated, bool altUpdat ed); void updateView(double az, double alt, bool azUpdated, bool altUpdat ed);
void setFov(double fov); void setFov(double fov);
void actionToggled(const QString& id, bool val); void actionToggled(const QString& id, bool val);
void propertyChanged(const QString& id, const QVariant& val); void propertyChanged(StelProperty* prop, const QVariant &val);
private: private:
StelCore* core; StelCore* core;
StelActionMgr* actionMgr; StelActionMgr* actionMgr;
LandscapeMgr* lsMgr; LandscapeMgr* lsMgr;
StelLocaleMgr* localeMgr; StelLocaleMgr* localeMgr;
StelMovementMgr* mvmgr; StelMovementMgr* mvmgr;
StelObjectMgr* objMgr; StelObjectMgr* objMgr;
StelPropertyMgr* propMgr; StelPropertyMgr* propMgr;
StelScriptMgr* scriptMgr; StelScriptMgr* scriptMgr;
StelSkyCultureMgr* skyCulMgr; StelSkyCultureMgr* skyCulMgr;
float moveX,moveY; double moveX,moveY;
qint64 lastMoveUpdateTime; qint64 lastMoveUpdateTime;
struct ActionCacheEntry struct ActionCacheEntry
{ {
ActionCacheEntry(const QString& str,bool val) : action(str), val(val) {} ActionCacheEntry(const QString& str,bool val) : action(str), val(val) {}
QString action; QString action;
bool val; bool val;
}; };
//lists the recently toggled actions - this is a pseudo-circular buf fer //lists the recently toggled actions - this is a pseudo-circular buf fer
 End of changes. 11 change blocks. 
10 lines changed or deleted 18 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/