Hi all,
My web application needs to have access to sockets (WebSockets is not an option in my case). The application will work in Webkit browser so I decided to write a plugin for webkit browser using Qt Webkit bridge technology. It seems that QTcpSocket should absolutely suite my needs.
But unfortunately after reading through the documentation on Qt Webkit bridge I didn't find any data type which will be suitable for passing binary data between plugin and JS application. In the documentation only a few data types which supposed to be automatically converted between Qt and JS are described.
The problem is that e.g. QIODevice::write method takes either char* or QByteArray.
After my investigation I can make a conclusion that the only way to pass binary data between Qt and JS is to pack it in string. But probably there are better ways for that.
Any suggestions are welcome. Thanks.
Bookmarks