From 10cad9ece2cb380e26e03a1c03b900f8e3b4c801 Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Mon, 23 May 2016 11:45:35 +0200 Subject: Doc: Also mention QML Import in index page qtwebsockets-index.html is the entry point for both C++ and QML API. Change-Id: I81efb2d7b931cce0d63efc2f25ce89904abcbfad Reviewed-by: Leena Miettinen --- src/websockets/doc/src/index.qdoc | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/src/websockets/doc/src/index.qdoc b/src/websockets/doc/src/index.qdoc index 9e1c40c..4f25589 100644 --- a/src/websockets/doc/src/index.qdoc +++ b/src/websockets/doc/src/index.qdoc @@ -41,15 +41,21 @@ Qt applications to act as a server that can process WebSocket requests, or a client that can consume data received from the server, or both. - To use this module in your application, use the following include - statement: + \section1 Getting Started + + To include the definitions of the module's classes, use the following directive: \code #include \endcode - To link against the module, add this line to your \l qmake \c - .pro file: + To import the QML types into your application, use the following import statement in your .qml file: + + \code + import QtWebSockets 1.0 + \endcode + + To link against the module, add this line to your qmake .pro file: \code QT += websockets -- cgit v1.2.1 From 04f50e048ff907885ac648782ef293d7aef66ace Mon Sep 17 00:00:00 2001 From: Sze Howe Koh Date: Wed, 15 Jun 2016 08:39:07 +0800 Subject: Expand license scope from "Qt GUI Toolkit" to "Qt Toolkit" See http://comments.gmane.org/gmane.comp.lib.qt.devel/25771 Change-Id: Ib20a0dc7d6e5c0d1ed906af5156d7d9a03e7a121 Reviewed-by: Lars Knoll --- LICENSE.GPLv3 | 2 +- LICENSE.LGPLv21 | 2 +- LICENSE.LGPLv3 | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/LICENSE.GPLv3 b/LICENSE.GPLv3 index 4e49b12..71c4ad4 100644 --- a/LICENSE.GPLv3 +++ b/LICENSE.GPLv3 @@ -3,7 +3,7 @@ The Qt Toolkit is Copyright (C) 2015 The Qt Company Ltd. Contact: http://www.qt.io/licensing/ - You may use, distribute and copy the Qt GUI Toolkit under the terms of + You may use, distribute and copy the Qt Toolkit under the terms of GNU Lesser General Public License version 3. That license references the General Public License version 3, that is displayed below. Other portions of the Qt Toolkit may be licensed directly under this license. diff --git a/LICENSE.LGPLv21 b/LICENSE.LGPLv21 index 6e18461..dfcab5e 100644 --- a/LICENSE.LGPLv21 +++ b/LICENSE.LGPLv21 @@ -3,7 +3,7 @@ The Qt Toolkit is Copyright (C) 2015 The Qt Company Ltd. Contact: http://www.qt.io/licensing/ - You may use, distribute and copy the Qt GUI Toolkit under the terms of + You may use, distribute and copy the Qt Toolkit under the terms of GNU Lesser General Public License version 2.1, which is displayed below. ------------------------------------------------------------------------- diff --git a/LICENSE.LGPLv3 b/LICENSE.LGPLv3 index 4d67bac..6bf924c 100644 --- a/LICENSE.LGPLv3 +++ b/LICENSE.LGPLv3 @@ -3,7 +3,7 @@ The Qt Toolkit is Copyright (C) 2015 The Qt Company Ltd. Contact: http://www.qt.io/licensing/ - You may use, distribute and copy the Qt GUI Toolkit under the terms of + You may use, distribute and copy the Qt Toolkit under the terms of GNU Lesser General Public License version 3, which is displayed below. This license makes reference to the version 3 of the GNU General Public License, which you can find in the LICENSE.GPLv3 file. -- cgit v1.2.1 From e66dcd51d0e5517e88cd59912fd08501522a2902 Mon Sep 17 00:00:00 2001 From: Oleksandr Tymoshenko Date: Thu, 19 May 2016 11:34:05 -0700 Subject: Fixed erroneous detection of server disconnect condition QAbstractSocket::atEnd does not check actual connection state it only checks if data is ready to be read. Under some conditions (e.g. slow network) data may not be available yet but it doesn't mean the server dropped connection. When more data comes FSM will pick it up and handle as expected. The right way to check disconnect is to check for actual socket state. Task-number: QTBUG-51069 Change-Id: I17d7110fbefdba2d5378a71935ab5923f8c1bf3e Reviewed-by: Thiago Macieira --- src/websockets/qwebsocket_p.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/websockets/qwebsocket_p.cpp b/src/websockets/qwebsocket_p.cpp index 2fd52fe..3df969e 100644 --- a/src/websockets/qwebsocket_p.cpp +++ b/src/websockets/qwebsocket_p.cpp @@ -975,7 +975,7 @@ void QWebSocketPrivate::processHandshake(QTcpSocket *pSocket) } if (m_handshakeState != ParsingHeaderState) { - if (pSocket->atEnd()) { + if (pSocket->state() != QAbstractSocket::ConnectedState) { errorDescription = QWebSocket::tr("QWebSocketPrivate::processHandshake: Connection closed while reading header."); break; } -- cgit v1.2.1