Added some support for QML debugging over USB. Fixed some issues with -qmljsdebugger option.

Not fully working over USB yet, there are some handshaking issues that need to be addressed. WLAN might be improved due to the -qmljsdebugger fixes, but not tested.
This commit is contained in:
Tom Sutcliffe
2011-02-23 12:10:51 +01:00
committed by Kai Koehne
parent ed79c97d83
commit 48fef07a08
4 changed files with 163 additions and 11 deletions

View File

@@ -49,7 +49,7 @@ QT_BEGIN_HEADER
namespace QmlJsDebugClient {
class QDeclarativeDebugConnectionPrivate;
class QDeclarativeDebugConnection : public QTcpSocket
class QDeclarativeDebugConnection : public QIODevice
{
Q_OBJECT
Q_DISABLE_COPY(QDeclarativeDebugConnection)
@@ -57,7 +57,25 @@ public:
QDeclarativeDebugConnection(QObject * = 0);
~QDeclarativeDebugConnection();
void connectToHost(const QString &hostName, quint16 port);
void connectToOst(const QString &port);
qint64 bytesAvailable() const;
bool isConnected() const;
QAbstractSocket::SocketState state() const;
void flush();
bool isSequential() const;
void close();
signals:
void connected();
void stateChanged(QAbstractSocket::SocketState socketState);
void error(QAbstractSocket::SocketError socketError);
private:
qint64 readData(char *data, qint64 maxSize);
qint64 writeData(const char *data, qint64 maxSize);
private:
QDeclarativeDebugConnectionPrivate *d;
friend class QDeclarativeDebugClient;