1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-13 20:01:46 -05:00
sdrangel/plugins/feature/satellitetracker/satellitetrackerreport.h

131 lines
3.9 KiB
C
Raw Normal View History

2021-02-26 15:25:48 -05:00
///////////////////////////////////////////////////////////////////////////////////
// Copyright (C) 2021-2022 Jon Beniston, M7RCE <jon@beniston.com> //
2021-02-26 15:25:48 -05:00
// //
// This program is free software; you can redistribute it and/or modify //
// it under the terms of the GNU General Public License as published by //
// the Free Software Foundation as version 3 of the License, or //
// (at your option) any later version. //
// //
// This program is distributed in the hope that it will be useful, //
// but WITHOUT ANY WARRANTY; without even the implied warranty of //
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
// GNU General Public License V3 for more details. //
// //
// You should have received a copy of the GNU General Public License //
// along with this program. If not, see <http://www.gnu.org/licenses/>. //
///////////////////////////////////////////////////////////////////////////////////
#ifndef INCLUDE_FEATURE_SATELLITETRACKERREPORT_H_
#define INCLUDE_FEATURE_SATELLITETRACKERREPORT_H_
#include <QObject>
#include "util/message.h"
#include "satellitetrackersgp4.h"
class SatelliteTrackerReport : public QObject
{
Q_OBJECT
public:
// Sent from worker to GUI to give latest satellite data
class MsgReportSat : public Message {
MESSAGE_CLASS_DECLARATION
public:
SatelliteState* getSatelliteState() const { return m_satState; }
static MsgReportSat* create(SatelliteState* satState)
{
return new MsgReportSat(satState);
}
private:
SatelliteState* m_satState;
MsgReportSat(SatelliteState* satState) :
Message(),
m_satState(satState)
{
}
};
// Sent from worker to GUI to indicate AOS
class MsgReportAOS : public Message {
MESSAGE_CLASS_DECLARATION
public:
QString getName() const { return m_name; }
QString getSpeech() const { return m_speech; }
2021-02-26 15:25:48 -05:00
static MsgReportAOS* create(const QString& name, const QString &speech)
2021-02-26 15:25:48 -05:00
{
return new MsgReportAOS(name, speech);
2021-02-26 15:25:48 -05:00
}
private:
QString m_name;
QString m_speech;
2021-02-26 15:25:48 -05:00
MsgReportAOS(const QString& name, const QString &speech) :
2021-02-26 15:25:48 -05:00
Message(),
m_name(name),
m_speech(speech)
2021-02-26 15:25:48 -05:00
{
}
};
2024-07-10 16:37:52 -04:00
// Sent from worker to GUI to indicate LOS
2021-02-26 15:25:48 -05:00
class MsgReportLOS : public Message {
MESSAGE_CLASS_DECLARATION
public:
QString getName() const { return m_name; }
QString getSpeech() const { return m_speech; }
2021-02-26 15:25:48 -05:00
static MsgReportLOS* create(const QString& name, const QString &speech)
2021-02-26 15:25:48 -05:00
{
return new MsgReportLOS(name, speech);
2021-02-26 15:25:48 -05:00
}
private:
QString m_name;
QString m_speech;
2021-02-26 15:25:48 -05:00
MsgReportLOS(const QString& name, const QString &speech) :
2021-02-26 15:25:48 -05:00
Message(),
m_name(name),
m_speech(speech)
2021-02-26 15:25:48 -05:00
{
}
};
// Sent from worker to GUI, to indicate target has changed
class MsgReportTarget : public Message {
MESSAGE_CLASS_DECLARATION
public:
QString getName() const { return m_name; }
static MsgReportTarget* create(const QString& name)
{
return new MsgReportTarget(name);
}
private:
QString m_name;
MsgReportTarget(const QString& name) :
Message(),
m_name(name)
{
}
};
public:
SatelliteTrackerReport() {}
~SatelliteTrackerReport() {}
};
#endif // INCLUDE_FEATURE_SATELLITETRACKERREPORT_H_