8 VPNSTATUS_INVALID
= -1,
10 VPNSTATUS_UNINITIALISED
,
11 VPNSTATUS_INITIALISING
,
14 VPNSTATUS_DISCONNECTING
,
19 class VPNControl
: public QObject
23 Q_PROPERTY (QString server READ getServer WRITE setServer NOTIFY serverChanged
)
24 Q_PROPERTY (unsigned int port READ getPort WRITE setPort NOTIFY portChanged
)
25 Q_PROPERTY (bool compressed READ getCompressed WRITE setCompressed NOTIFY compressedChanged
)
26 Q_PROPERTY (bool useTLS READ getUseTLS WRITE setUseTLS NOTIFY useTLSChanged
)
27 Q_PROPERTY (int tlsDirection READ getTlsDirection WRITE setTlsDirection NOTIFY tlsDirectionChanged
)
30 QProcess
* vpnProcess
;
32 void setStatus (VPNSTATUS newStatus
);
40 explicit VPNControl(QObject
*parent
= 0);
42 QString
getServer() const;
43 unsigned int getPort() const;
44 bool getCompressed() const;
45 bool getUseTLS() const;
46 int getTlsDirection() const;
49 void statusChanged(int status
);
50 void serverChanged(QString server
);
51 void portChanged(unsigned int port
);
52 void compressedChanged(bool compressed
);
53 void useTLSChanged(bool useTLS
);
54 void tlsDirectionChanged (int direction
);
58 void vpnDisconnect ();
61 void finished (int code
);
62 void readError (QProcess::ProcessError error
);
63 void updateConfiguration ();
64 void setServer(const QString
&value
);
65 void setPort(unsigned int value
);
66 void setCompressed(bool value
);
67 void setUseTLS(bool value
);
68 void setTlsDirection(int value
);
71 #endif // VPNCONTROL_H