WireGuard rework for MacOS and Windows (#314)
WireGuard rework for MacOS and Windows
This commit is contained in:
parent
421a27ceae
commit
07c38e9b6c
60 changed files with 4779 additions and 434 deletions
34
client/platforms/windows/windowspingsender.h
Normal file
34
client/platforms/windows/windowspingsender.h
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#ifndef WINDOWSPINGSENDER_H
|
||||
#define WINDOWSPINGSENDER_H
|
||||
|
||||
#include <QMap>
|
||||
#include <QWinEventNotifier>
|
||||
|
||||
#include "pingsender.h"
|
||||
|
||||
struct WindowsPingSenderPrivate;
|
||||
|
||||
class WindowsPingSender final : public PingSender {
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY_MOVE(WindowsPingSender)
|
||||
|
||||
public:
|
||||
WindowsPingSender(const QHostAddress& source, QObject* parent = nullptr);
|
||||
~WindowsPingSender();
|
||||
|
||||
void sendPing(const QHostAddress& destination, quint16 sequence) override;
|
||||
|
||||
private slots:
|
||||
void pingEventReady();
|
||||
|
||||
private:
|
||||
QHostAddress m_source;
|
||||
QWinEventNotifier* m_notifier = nullptr;
|
||||
struct WindowsPingSenderPrivate* m_private = nullptr;
|
||||
};
|
||||
|
||||
#endif // WINDOWSPINGSENDER_H
|
||||
Loading…
Add table
Add a link
Reference in a new issue