CodeLibrary/04_QtCreator_Cplus_TCPClient_20240423/cheat.h
2024-04-24 23:08:17 +08:00

36 lines
517 B
C++

#ifndef CHEAT_H
#define CHEAT_H
#include <QWidget>
// 包含 TCP 库
#include <QTcpSocket>
#include <QHostAddress>
#include <QDateTime>
#include <widget.h>
namespace Ui {
class cheat;
}
class cheat : public QWidget
{
Q_OBJECT
public:
explicit cheat(QTcpSocket *s, QWidget *parent = nullptr);
~cheat();
private slots:
void on_Clear_Button_clicked();
void on_Send_Button_clicked();
private:
Ui::cheat *ui;
// 实例化 QTcpSocket 对象
QTcpSocket *socket;
};
#endif // CHEAT_H