diff options
Diffstat (limited to 'tests/manual/examples/quick/customdialogs/server.h')
-rw-r--r-- | tests/manual/examples/quick/customdialogs/server.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/tests/manual/examples/quick/customdialogs/server.h b/tests/manual/examples/quick/customdialogs/server.h new file mode 100644 index 000000000..563465013 --- /dev/null +++ b/tests/manual/examples/quick/customdialogs/server.h @@ -0,0 +1,29 @@ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause + +#ifndef SERVER_H +#define SERVER_H + +#include <QObject> +#include <QTcpServer> + +class Server : public QObject +{ + Q_OBJECT + +public: + explicit Server(QObject *parent = nullptr); + +public slots: + void run(); + +private slots: + void handleNewConnection(); + void handleReadReady(); + +private: + QTcpServer m_server; + QByteArray m_data; +}; + +#endif // SERVER_H |