Details
-
Type:
Bug
-
Status: Reported
-
Priority:
P4: Low
-
Resolution: Unresolved
-
Affects Version/s: 5.8.0 RC
-
Fix Version/s: None
-
Component/s: Documentation, Quick: Other
-
Labels:None
-
Environment:All
Description
Hi,
There's an error that sliped into the documentation of the QML WebSocket Type of the newly implemented receiveBinaryMessage() signal.
The documentation states that the signal's argument is a QString, when in fact it's an ArrayBuffer - as described for the sendBinaryMessage() method.
The error can be found in the patch that implements these functionalities :
https://github.com/qt/qtwebsockets/commit/9b804c270d11d34d37c08a5145dba083a6b0c1a7#diff-972828f3f4fa4303180be85da2f35d7aR94
Documentation page :
http://doc-snapshots.qt.io/qt5-5.8/qml-qtwebsockets-websocket.html#sendBinaryMessage-method
This affects the documentation and the helpers in QtCreator - which expect a string.
PS: it would certainly be interesting to give some example(s) of how to handle this binary data in QML. I myself haven't yet figured out how to use an image received that way.