summaryrefslogtreecommitdiffhomepage
path: root/proto-udp/ftnoir_protocol_ftn.h
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2017-12-03 22:23:08 +0100
committerStanislaw Halik <sthalik@misaki.pl>2017-12-04 12:19:26 +0100
commitb256886a5cb9f2ae3ebda70a2045b19ed9f4233e (patch)
tree4fa1e46de224cf834a05824dc1eb86001bdb3300 /proto-udp/ftnoir_protocol_ftn.h
parente89709a801e7874bc02c66848c638c6a0ccc85c1 (diff)
api: add status check for modules
Diffstat (limited to 'proto-udp/ftnoir_protocol_ftn.h')
-rw-r--r--proto-udp/ftnoir_protocol_ftn.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/proto-udp/ftnoir_protocol_ftn.h b/proto-udp/ftnoir_protocol_ftn.h
index b234cd89..7838f01a 100644
--- a/proto-udp/ftnoir_protocol_ftn.h
+++ b/proto-udp/ftnoir_protocol_ftn.h
@@ -31,11 +31,13 @@ struct settings : opts {
{}
};
-class udp : public IProtocol
+class udp : public QObject, public IProtocol
{
+ Q_OBJECT
+
public:
udp();
- bool correct();
+ module_status check_status() override;
void pose(const double *headpose);
QString game_name() {
return QCoreApplication::translate("udp_proto", "UDP over network");
@@ -43,12 +45,19 @@ public:
private:
QUdpSocket outSocket;
settings s;
+
+ QHostAddress dest_ip { 127u << 24 | 1u };
+ unsigned short dest_port = 65535;
+
+private slots:
+ void set_dest_address();
};
// Widget that has controls for FTNoIR protocol client-settings.
class FTNControls: public IProtocolDialog
{
Q_OBJECT
+
public:
FTNControls();
void register_protocol(IProtocol *) {}