Network chat: make ctors explicit
Task-number: QTBUG-108873 Change-Id: I08cd676aeb732d32b4d1e7d13a0aa1b37a46283f Reviewed-by: Konrad Kujawa <konrad.kujawa@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
This commit is contained in:
parent
3ece5e30b7
commit
61afc6d109
@ -12,7 +12,7 @@ class ChatDialog : public QDialog, private Ui::ChatDialog
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
ChatDialog(QWidget *parent = nullptr);
|
explicit ChatDialog(QWidget *parent = nullptr);
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void appendMessage(const QString &from, const QString &message);
|
void appendMessage(const QString &from, const QString &message);
|
||||||
|
@ -32,8 +32,8 @@ public:
|
|||||||
Undefined
|
Undefined
|
||||||
};
|
};
|
||||||
|
|
||||||
Connection(QObject *parent = nullptr);
|
explicit Connection(QObject *parent = nullptr);
|
||||||
Connection(qintptr socketDescriptor, QObject *parent = nullptr);
|
explicit Connection(qintptr socketDescriptor, QObject *parent = nullptr);
|
||||||
~Connection();
|
~Connection();
|
||||||
|
|
||||||
QString name() const;
|
QString name() const;
|
||||||
|
@ -18,7 +18,7 @@ class PeerManager : public QObject
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
PeerManager(Client *client);
|
explicit PeerManager(Client *client);
|
||||||
|
|
||||||
void setServerPort(int port);
|
void setServerPort(int port);
|
||||||
QString userName() const;
|
QString userName() const;
|
||||||
|
@ -13,7 +13,7 @@ class Server : public QTcpServer
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
Server(QObject *parent = nullptr);
|
explicit Server(QObject *parent = nullptr);
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void newConnection(Connection *connection);
|
void newConnection(Connection *connection);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user