diff options
author | Ulf Hermann <ulf.hermann@theqtcompany.com> | 2015-06-16 13:40:08 +0200 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@theqtcompany.com> | 2015-08-04 13:34:48 +0000 |
commit | a010f3a8f92a9a364e9d17d12b06074fde6f8a17 (patch) | |
tree | 33a3a91f63d8daa4a5a939a4af4e29812c803bc0 /src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h | |
parent | 31291359a327c5ffa6aa3aff76b62491782408d7 (diff) |
Deduplicate debug server connection code.
The packet protocol can be part of the server, now that the server is
not part of QtQml anymore. This enables us to remove some duplicated
code from the connections.
As an added benefit, with more control over the sending process,
QQmlDebugServer can now efficiently send single packets, without
creating a QList<QByteArray> first.
Change-Id: I13cc831e254c02b737e64816d6d3ab051d760995
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Diffstat (limited to 'src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h')
-rw-r--r-- | src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h b/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h index 68271abfe6..8b2aed0b55 100644 --- a/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h +++ b/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h @@ -56,19 +56,17 @@ public: bool setFileName(const QString &fileName, bool block); bool isConnected() const; - void send(const QList<QByteArray> &messages); void disconnect(); - bool waitForMessage(); - bool listen(); void waitForConnection(); + void flush(); private Q_SLOTS: - void readyRead(); void newConnection(); - void invalidPacket(); private: + bool listen(); + QTcpServerConnectionPrivate *d_ptr; }; |