diff --git a/src/declarative/debugger/qdebugmessageservice.cpp b/src/declarative/debugger/qdebugmessageservice.cpp index 10a4a718c28293c1e29ff8d5e6492f10a5baef3d..e7c4901a4873b2a265eb754a8057cb57cdc541ed 100644 --- a/src/declarative/debugger/qdebugmessageservice.cpp +++ b/src/declarative/debugger/qdebugmessageservice.cpp @@ -56,12 +56,12 @@ class QDebugMessageServicePrivate : public QDeclarativeDebugServicePrivate public: QDebugMessageServicePrivate() : oldMsgHandler(0) - , prevStatus(QDeclarativeDebugService::NotConnected) + , prevState(QDeclarativeDebugService::NotConnected) { } QtMsgHandler oldMsgHandler; - QDeclarativeDebugService::Status prevStatus; + QDeclarativeDebugService::State prevState; }; QDebugMessageService::QDebugMessageService(QObject *parent) : @@ -71,9 +71,9 @@ QDebugMessageService::QDebugMessageService(QObject *parent) : Q_D(QDebugMessageService); registerService(); - if (status() == Enabled) { + if (state() == Enabled) { d->oldMsgHandler = qInstallMsgHandler(DebugMessageHandler); - d->prevStatus = Enabled; + d->prevState = Enabled; } } @@ -98,22 +98,22 @@ void QDebugMessageService::sendDebugMessage(QtMsgType type, const char *buf) (*d->oldMsgHandler)(type, buf); } -void QDebugMessageService::statusChanged(Status status) +void QDebugMessageService::stateChanged(State state) { Q_D(QDebugMessageService); - if (status != Enabled && d->prevStatus == Enabled) { + if (state != Enabled && d->prevState == Enabled) { QtMsgHandler handler = qInstallMsgHandler(d->oldMsgHandler); // has our handler been overwritten in between? if (handler != DebugMessageHandler) qInstallMsgHandler(handler); - } else if (status == Enabled && d->prevStatus != Enabled) { + } else if (state == Enabled && d->prevState != Enabled) { d->oldMsgHandler = qInstallMsgHandler(DebugMessageHandler); } - d->prevStatus = status; + d->prevState = state; } QT_END_NAMESPACE diff --git a/src/declarative/debugger/qdebugmessageservice_p.h b/src/declarative/debugger/qdebugmessageservice_p.h index 4f25c7b673a9e385e944878de2685dbe008c63d3..bf0e17c2fecec280aba79c826a97aba9a8a4cc4f 100644 --- a/src/declarative/debugger/qdebugmessageservice_p.h +++ b/src/declarative/debugger/qdebugmessageservice_p.h @@ -74,7 +74,7 @@ public: void sendDebugMessage(QtMsgType type, const char *buf); protected: - void statusChanged(Status); + void stateChanged(State); private: Q_DISABLE_COPY(QDebugMessageService) diff --git a/src/declarative/debugger/qdeclarativedebugclient.cpp b/src/declarative/debugger/qdeclarativedebugclient.cpp index a3e0c838496fb0789a3da1cb2119dd103659a9f3..df250f3ef659b1b6fecbc6a3e2f403a077729bec 100644 --- a/src/declarative/debugger/qdeclarativedebugclient.cpp +++ b/src/declarative/debugger/qdeclarativedebugclient.cpp @@ -159,10 +159,10 @@ void QDeclarativeDebugConnectionPrivate::readyRead() QHash<QString, QDeclarativeDebugClient *>::Iterator iter = plugins.begin(); for (; iter != plugins.end(); ++iter) { - QDeclarativeDebugClient::Status newStatus = QDeclarativeDebugClient::Unavailable; + QDeclarativeDebugClient::State newState = QDeclarativeDebugClient::Unavailable; if (serverPlugins.contains(iter.key())) - newStatus = QDeclarativeDebugClient::Enabled; - iter.value()->statusChanged(newStatus); + newState = QDeclarativeDebugClient::Enabled; + iter.value()->stateChanged(newState); } } @@ -198,13 +198,13 @@ void QDeclarativeDebugConnectionPrivate::readyRead() QHash<QString, QDeclarativeDebugClient *>::Iterator iter = plugins.begin(); for (; iter != plugins.end(); ++iter) { const QString pluginName = iter.key(); - QDeclarativeDebugClient::Status newStatus = QDeclarativeDebugClient::Unavailable; + QDeclarativeDebugClient::State newSate = QDeclarativeDebugClient::Unavailable; if (serverPlugins.contains(pluginName)) - newStatus = QDeclarativeDebugClient::Enabled; + newSate = QDeclarativeDebugClient::Enabled; if (oldServerPlugins.contains(pluginName) != serverPlugins.contains(pluginName)) { - iter.value()->statusChanged(newStatus); + iter.value()->stateChanged(newSate); } } } else { @@ -242,7 +242,7 @@ QDeclarativeDebugConnection::~QDeclarativeDebugConnection() QHash<QString, QDeclarativeDebugClient*>::iterator iter = d->plugins.begin(); for (; iter != d->plugins.end(); ++iter) { iter.value()->d_func()->connection = 0; - iter.value()->statusChanged(QDeclarativeDebugClient::NotConnected); + iter.value()->stateChanged(QDeclarativeDebugClient::NotConnected); } } @@ -280,7 +280,7 @@ void QDeclarativeDebugConnection::close() QHash<QString, QDeclarativeDebugClient*>::iterator iter = d->plugins.begin(); for (; iter != d->plugins.end(); ++iter) { - iter.value()->statusChanged(QDeclarativeDebugClient::NotConnected); + iter.value()->stateChanged(QDeclarativeDebugClient::NotConnected); } } } @@ -382,7 +382,7 @@ float QDeclarativeDebugClient::serviceVersion() const return -1; } -QDeclarativeDebugClient::Status QDeclarativeDebugClient::status() const +QDeclarativeDebugClient::State QDeclarativeDebugClient::state() const { Q_D(const QDeclarativeDebugClient); if (!d->connection @@ -399,7 +399,7 @@ QDeclarativeDebugClient::Status QDeclarativeDebugClient::status() const void QDeclarativeDebugClient::sendMessage(const QByteArray &message) { Q_D(QDeclarativeDebugClient); - if (status() != Enabled) + if (state() != Enabled) return; QPacket pack; @@ -408,7 +408,7 @@ void QDeclarativeDebugClient::sendMessage(const QByteArray &message) d->connection->flush(); } -void QDeclarativeDebugClient::statusChanged(Status) +void QDeclarativeDebugClient::stateChanged(State) { } diff --git a/src/declarative/debugger/qdeclarativedebugclient_p.h b/src/declarative/debugger/qdeclarativedebugclient_p.h index ff4f88f40827608eb8388469b4034747269f37fd..93c5be9e449be6cedf1017944cf05df1ea166be1 100644 --- a/src/declarative/debugger/qdeclarativedebugclient_p.h +++ b/src/declarative/debugger/qdeclarativedebugclient_p.h @@ -104,19 +104,19 @@ class Q_DECLARATIVE_PRIVATE_EXPORT QDeclarativeDebugClient : public QObject Q_DISABLE_COPY(QDeclarativeDebugClient) public: - enum Status { NotConnected, Unavailable, Enabled }; + enum State { NotConnected, Unavailable, Enabled }; QDeclarativeDebugClient(const QString &, QDeclarativeDebugConnection *parent); ~QDeclarativeDebugClient(); QString name() const; float serviceVersion() const; - Status status() const; + State state() const; virtual void sendMessage(const QByteArray &); protected: - virtual void statusChanged(Status); + virtual void stateChanged(State); virtual void messageReceived(const QByteArray &); private: diff --git a/src/declarative/debugger/qdeclarativedebugserver.cpp b/src/declarative/debugger/qdeclarativedebugserver.cpp index d4c203f1f7f587062723e022ac21a0656e81d2a1..482847c7a7485a7b73fb1dd29d8db61c89afeef2 100644 --- a/src/declarative/debugger/qdeclarativedebugserver.cpp +++ b/src/declarative/debugger/qdeclarativedebugserver.cpp @@ -329,10 +329,10 @@ QDeclarativeDebugServer::~QDeclarativeDebugServer() QReadLocker(&d->pluginsLock); { foreach (QDeclarativeDebugService *service, d->plugins.values()) { - service->statusAboutToBeChanged(QDeclarativeDebugService::NotConnected); + service->stateAboutToBeChanged(QDeclarativeDebugService::NotConnected); service->d_func()->server = 0; - service->d_func()->status = QDeclarativeDebugService::NotConnected; - service->statusChanged(QDeclarativeDebugService::NotConnected); + service->d_func()->state = QDeclarativeDebugService::NotConnected; + service->stateChanged(QDeclarativeDebugService::NotConnected); } } @@ -381,11 +381,11 @@ void QDeclarativeDebugServer::receiveMessage(const QByteArray &message) QReadLocker(&d->pluginsLock); QHash<QString, QDeclarativeDebugService*>::ConstIterator iter = d->plugins.constBegin(); for (; iter != d->plugins.constEnd(); ++iter) { - QDeclarativeDebugService::Status newStatus = QDeclarativeDebugService::Unavailable; + QDeclarativeDebugService::State newState = QDeclarativeDebugService::Unavailable; if (d->clientPlugins.contains(iter.key())) - newStatus = QDeclarativeDebugService::Enabled; - iter.value()->d_func()->status = newStatus; - iter.value()->statusChanged(newStatus); + newState = QDeclarativeDebugService::Enabled; + iter.value()->d_func()->state = newState; + iter.value()->stateChanged(newState); } qWarning("QDeclarativeDebugServer: Connection established"); @@ -401,14 +401,14 @@ void QDeclarativeDebugServer::receiveMessage(const QByteArray &message) QHash<QString, QDeclarativeDebugService*>::ConstIterator iter = d->plugins.constBegin(); for (; iter != d->plugins.constEnd(); ++iter) { const QString pluginName = iter.key(); - QDeclarativeDebugService::Status newStatus = QDeclarativeDebugService::Unavailable; + QDeclarativeDebugService::State newState = QDeclarativeDebugService::Unavailable; if (d->clientPlugins.contains(pluginName)) - newStatus = QDeclarativeDebugService::Enabled; + newState = QDeclarativeDebugService::Enabled; if (oldClientPlugins.contains(pluginName) != d->clientPlugins.contains(pluginName)) { - iter.value()->d_func()->status = newStatus; - iter.value()->statusChanged(newStatus); + iter.value()->d_func()->state = newState; + iter.value()->stateChanged(newState); } } @@ -472,10 +472,10 @@ bool QDeclarativeDebugServer::addService(QDeclarativeDebugService *service) { QReadLocker(&d->pluginsLock); d->advertisePlugins(); - QDeclarativeDebugService::Status newStatus = QDeclarativeDebugService::Unavailable; + QDeclarativeDebugService::State newState = QDeclarativeDebugService::Unavailable; if (d->clientPlugins.contains(service->name())) - newStatus = QDeclarativeDebugService::Enabled; - service->d_func()->status = newStatus; + newState = QDeclarativeDebugService::Enabled; + service->d_func()->state = newState; } return true; } @@ -491,12 +491,12 @@ bool QDeclarativeDebugServer::removeService(QDeclarativeDebugService *service) } { QReadLocker(&d->pluginsLock); - QDeclarativeDebugService::Status newStatus = QDeclarativeDebugService::NotConnected; - service->statusAboutToBeChanged(newStatus); + QDeclarativeDebugService::State newState = QDeclarativeDebugService::NotConnected; + service->stateAboutToBeChanged(newState); d->advertisePlugins(); service->d_func()->server = 0; - service->d_func()->status = newStatus; - service->statusChanged(newStatus); + service->d_func()->state = newState; + service->stateChanged(newState); } return true; diff --git a/src/declarative/debugger/qdeclarativedebugservice.cpp b/src/declarative/debugger/qdeclarativedebugservice.cpp index 98d95d7b34f241c70fb561905d4153747e8aa1d6..96344d771772cbd5e91c8f782fceafa958222ba8 100644 --- a/src/declarative/debugger/qdeclarativedebugservice.cpp +++ b/src/declarative/debugger/qdeclarativedebugservice.cpp @@ -60,7 +60,7 @@ QDeclarativeDebugService::QDeclarativeDebugService(const QString &name, float ve d->name = name; d->version = version; d->server = QDeclarativeDebugServer::instance(); - d->status = QDeclarativeDebugService::NotConnected; + d->state = QDeclarativeDebugService::NotConnected; } @@ -73,14 +73,14 @@ QDeclarativeDebugService::QDeclarativeDebugService(QDeclarativeDebugServicePriva d->name = name; d->version = version; d->server = QDeclarativeDebugServer::instance(); - d->status = QDeclarativeDebugService::NotConnected; + d->state = QDeclarativeDebugService::NotConnected; } /** Registers the service. This should be called in the constructor of the inherited class. From then on the service might get asynchronous calls to messageReceived(). */ -QDeclarativeDebugService::Status QDeclarativeDebugService::registerService() +QDeclarativeDebugService::State QDeclarativeDebugService::registerService() { Q_D(QDeclarativeDebugService); if (!d->server) @@ -92,7 +92,7 @@ QDeclarativeDebugService::Status QDeclarativeDebugService::registerService() } else { d->server->addService(this); } - return status(); + return state(); } QDeclarativeDebugService::~QDeclarativeDebugService() @@ -115,10 +115,10 @@ float QDeclarativeDebugService::version() const return d->version; } -QDeclarativeDebugService::Status QDeclarativeDebugService::status() const +QDeclarativeDebugService::State QDeclarativeDebugService::state() const { Q_D(const QDeclarativeDebugService); - return d->status; + return d->state; } namespace { @@ -237,7 +237,7 @@ void QDeclarativeDebugService::sendMessages(const QList<QByteArray> &messages) { Q_D(QDeclarativeDebugService); - if (status() != Enabled) + if (state() != Enabled) return; d->server->sendMessages(this, messages); @@ -247,17 +247,17 @@ bool QDeclarativeDebugService::waitForMessage() { Q_D(QDeclarativeDebugService); - if (status() != Enabled) + if (state() != Enabled) return false; return d->server->waitForMessage(this); } -void QDeclarativeDebugService::statusAboutToBeChanged(Status) +void QDeclarativeDebugService::stateAboutToBeChanged(State) { } -void QDeclarativeDebugService::statusChanged(Status) +void QDeclarativeDebugService::stateChanged(State) { } diff --git a/src/declarative/debugger/qdeclarativedebugservice_p.h b/src/declarative/debugger/qdeclarativedebugservice_p.h index 7cce2ba86b9ce940ba4231d75f766cdbd32c40bc..203e27ad09e4bbd54881e34cf75f3c480d0e6fad 100644 --- a/src/declarative/debugger/qdeclarativedebugservice_p.h +++ b/src/declarative/debugger/qdeclarativedebugservice_p.h @@ -76,8 +76,8 @@ public: QString name() const; float version() const; - enum Status { NotConnected, Unavailable, Enabled }; - Status status() const; + enum State { NotConnected, Unavailable, Enabled }; + State state() const; void sendMessage(const QByteArray &); void sendMessages(const QList<QByteArray> &); @@ -94,10 +94,10 @@ public: protected: QDeclarativeDebugService(QDeclarativeDebugServicePrivate &dd, const QString &name, float version, QObject *parent = 0); - Status registerService(); + State registerService(); - virtual void statusAboutToBeChanged(Status); - virtual void statusChanged(Status); + virtual void stateAboutToBeChanged(State); + virtual void stateChanged(State); virtual void messageReceived(const QByteArray &); private: diff --git a/src/declarative/debugger/qdeclarativedebugservice_p_p.h b/src/declarative/debugger/qdeclarativedebugservice_p_p.h index 868f6ca7cf1869d5a8a42d15d1c18afd2d28856f..6638ccbec75928914f686147f802e90eb3a713fd 100644 --- a/src/declarative/debugger/qdeclarativedebugservice_p_p.h +++ b/src/declarative/debugger/qdeclarativedebugservice_p_p.h @@ -72,7 +72,7 @@ public: QString name; float version; QDeclarativeDebugServer *server; - QDeclarativeDebugService::Status status; + QDeclarativeDebugService::State state; }; QT_END_NAMESPACE diff --git a/src/declarative/debugger/qdeclarativedebugtrace.cpp b/src/declarative/debugger/qdeclarativedebugtrace.cpp index 5f8a61cc3b53053b3b8e54df94e5dd99852dc6be..3c718604d87bf6b9bbb5b8d2b9fc4ff6f7ec20a8 100644 --- a/src/declarative/debugger/qdeclarativedebugtrace.cpp +++ b/src/declarative/debugger/qdeclarativedebugtrace.cpp @@ -310,12 +310,12 @@ void QDeclarativeDebugTrace::sendMessages() QDeclarativeDebugService::sendMessages(messages); } -void QDeclarativeDebugTrace::statusAboutToBeChanged(QDeclarativeDebugService::Status newStatus) +void QDeclarativeDebugTrace::stateAboutToBeChanged(QDeclarativeDebugService::State newState) { - if (status() == newStatus) + if (state() == newState) return; - if (status() == Enabled + if (state() == Enabled && m_enabled) { stopProfilingImpl(); sendMessages(); diff --git a/src/declarative/debugger/qdeclarativedebugtrace_p.h b/src/declarative/debugger/qdeclarativedebugtrace_p.h index 0701f35617e552315d1d863350628930efa93ce2..7e2db4dbadbf80f3a406aa5370d775b70ec5e832 100644 --- a/src/declarative/debugger/qdeclarativedebugtrace_p.h +++ b/src/declarative/debugger/qdeclarativedebugtrace_p.h @@ -145,7 +145,7 @@ public: ~QDeclarativeDebugTrace(); protected: - virtual void statusAboutToBeChanged(Status status); + virtual void stateAboutToBeChanged(State state); virtual void messageReceived(const QByteArray &); private: diff --git a/src/declarative/debugger/qdeclarativeenginedebug.cpp b/src/declarative/debugger/qdeclarativeenginedebug.cpp index c6f09f193df360572c62b1f7a052cc728903a675..462f99937ef14cba9b29a24147e2700059d87019 100644 --- a/src/declarative/debugger/qdeclarativeenginedebug.cpp +++ b/src/declarative/debugger/qdeclarativeenginedebug.cpp @@ -55,7 +55,7 @@ public: QDeclarativeEngineDebugClient(QDeclarativeDebugConnection *client, QDeclarativeEngineDebugPrivate *p); protected: - virtual void statusChanged(Status status); + virtual void stateChanged(State state); virtual void messageReceived(const QByteArray &); private: @@ -70,7 +70,7 @@ public: QDeclarativeEngineDebugPrivate(QDeclarativeDebugConnection *); ~QDeclarativeEngineDebugPrivate(); - void statusChanged(QDeclarativeEngineDebug::Status status); + void stateChanged(QDeclarativeEngineDebug::State status); void message(const QByteArray &); QDeclarativeEngineDebugClient *client; @@ -100,10 +100,10 @@ QDeclarativeEngineDebugClient::QDeclarativeEngineDebugClient(QDeclarativeDebugCo { } -void QDeclarativeEngineDebugClient::statusChanged(Status status) +void QDeclarativeEngineDebugClient::stateChanged(State status) { if (priv) - priv->statusChanged(static_cast<QDeclarativeEngineDebug::Status>(status)); + priv->stateChanged(static_cast<QDeclarativeEngineDebug::State>(status)); } void QDeclarativeEngineDebugClient::messageReceived(const QByteArray &data) @@ -288,9 +288,9 @@ void QDeclarativeEngineDebugPrivate::decode(QDataStream &ds, QDeclarativeDebugCo } } -void QDeclarativeEngineDebugPrivate::statusChanged(QDeclarativeEngineDebug::Status status) +void QDeclarativeEngineDebugPrivate::stateChanged(QDeclarativeEngineDebug::State status) { - emit q_func()->statusChanged(status); + emit q_func()->stateChanged(status); } void QDeclarativeEngineDebugPrivate::message(const QByteArray &data) @@ -419,11 +419,11 @@ QDeclarativeEngineDebug::~QDeclarativeEngineDebug() { } -QDeclarativeEngineDebug::Status QDeclarativeEngineDebug::status() const +QDeclarativeEngineDebug::State QDeclarativeEngineDebug::state() const { Q_D(const QDeclarativeEngineDebug); - return static_cast<QDeclarativeEngineDebug::Status>(d->client->status()); + return static_cast<QDeclarativeEngineDebug::State>(d->client->state()); } QDeclarativeDebugPropertyWatch *QDeclarativeEngineDebug::addWatch(const QDeclarativeDebugPropertyReference &property, QObject *parent) @@ -431,7 +431,7 @@ QDeclarativeDebugPropertyWatch *QDeclarativeEngineDebug::addWatch(const QDeclara Q_D(QDeclarativeEngineDebug); QDeclarativeDebugPropertyWatch *watch = new QDeclarativeDebugPropertyWatch(parent); - if (d->client->status() == QDeclarativeDebugClient::Enabled) { + if (d->client->state() == QDeclarativeDebugClient::Enabled) { int queryId = d->getId(); watch->m_queryId = queryId; watch->m_client = this; @@ -460,7 +460,7 @@ QDeclarativeDebugObjectExpressionWatch *QDeclarativeEngineDebug::addWatch(const { Q_D(QDeclarativeEngineDebug); QDeclarativeDebugObjectExpressionWatch *watch = new QDeclarativeDebugObjectExpressionWatch(parent); - if (d->client->status() == QDeclarativeDebugClient::Enabled) { + if (d->client->state() == QDeclarativeDebugClient::Enabled) { int queryId = d->getId(); watch->m_queryId = queryId; watch->m_client = this; @@ -483,7 +483,7 @@ QDeclarativeDebugWatch *QDeclarativeEngineDebug::addWatch(const QDeclarativeDebu Q_D(QDeclarativeEngineDebug); QDeclarativeDebugWatch *watch = new QDeclarativeDebugWatch(parent); - if (d->client->status() == QDeclarativeDebugClient::Enabled) { + if (d->client->state() == QDeclarativeDebugClient::Enabled) { int queryId = d->getId(); watch->m_queryId = queryId; watch->m_client = this; @@ -519,7 +519,7 @@ void QDeclarativeEngineDebug::removeWatch(QDeclarativeDebugWatch *watch) d->watched.remove(watch->queryId()); - if (d->client && d->client->status() == QDeclarativeDebugClient::Enabled) { + if (d->client && d->client->state() == QDeclarativeDebugClient::Enabled) { QByteArray message; QDataStream ds(&message, QIODevice::WriteOnly); ds << QByteArray("NO_WATCH") << watch->queryId(); @@ -532,7 +532,7 @@ QDeclarativeDebugEnginesQuery *QDeclarativeEngineDebug::queryAvailableEngines(QO Q_D(QDeclarativeEngineDebug); QDeclarativeDebugEnginesQuery *query = new QDeclarativeDebugEnginesQuery(parent); - if (d->client->status() == QDeclarativeDebugClient::Enabled) { + if (d->client->state() == QDeclarativeDebugClient::Enabled) { query->m_client = this; int queryId = d->getId(); query->m_queryId = queryId; @@ -554,7 +554,7 @@ QDeclarativeDebugRootContextQuery *QDeclarativeEngineDebug::queryRootContexts(co Q_D(QDeclarativeEngineDebug); QDeclarativeDebugRootContextQuery *query = new QDeclarativeDebugRootContextQuery(parent); - if (d->client->status() == QDeclarativeDebugClient::Enabled && engine.debugId() != -1) { + if (d->client->state() == QDeclarativeDebugClient::Enabled && engine.debugId() != -1) { query->m_client = this; int queryId = d->getId(); query->m_queryId = queryId; @@ -576,7 +576,7 @@ QDeclarativeDebugObjectQuery *QDeclarativeEngineDebug::queryObject(const QDeclar Q_D(QDeclarativeEngineDebug); QDeclarativeDebugObjectQuery *query = new QDeclarativeDebugObjectQuery(parent); - if (d->client->status() == QDeclarativeDebugClient::Enabled && object.debugId() != -1) { + if (d->client->state() == QDeclarativeDebugClient::Enabled && object.debugId() != -1) { query->m_client = this; int queryId = d->getId(); query->m_queryId = queryId; @@ -599,7 +599,7 @@ QDeclarativeDebugObjectQuery *QDeclarativeEngineDebug::queryObjectRecursive(cons Q_D(QDeclarativeEngineDebug); QDeclarativeDebugObjectQuery *query = new QDeclarativeDebugObjectQuery(parent); - if (d->client->status() == QDeclarativeDebugClient::Enabled && object.debugId() != -1) { + if (d->client->state() == QDeclarativeDebugClient::Enabled && object.debugId() != -1) { query->m_client = this; int queryId = d->getId(); query->m_queryId = queryId; @@ -622,7 +622,7 @@ QDeclarativeDebugExpressionQuery *QDeclarativeEngineDebug::queryExpressionResult Q_D(QDeclarativeEngineDebug); QDeclarativeDebugExpressionQuery *query = new QDeclarativeDebugExpressionQuery(parent); - if (d->client->status() == QDeclarativeDebugClient::Enabled && objectDebugId != -1) { + if (d->client->state() == QDeclarativeDebugClient::Enabled && objectDebugId != -1) { query->m_client = this; query->m_expr = expr; int queryId = d->getId(); @@ -647,7 +647,7 @@ bool QDeclarativeEngineDebug::setBindingForObject(int objectDebugId, const QStri { Q_D(QDeclarativeEngineDebug); - if (d->client->status() == QDeclarativeDebugClient::Enabled && objectDebugId != -1) { + if (d->client->state() == QDeclarativeDebugClient::Enabled && objectDebugId != -1) { QByteArray message; QDataStream ds(&message, QIODevice::WriteOnly); ds << QByteArray("SET_BINDING") << objectDebugId << propertyName << bindingExpression << isLiteralValue << source << line; @@ -662,7 +662,7 @@ bool QDeclarativeEngineDebug::resetBindingForObject(int objectDebugId, const QSt { Q_D(QDeclarativeEngineDebug); - if (d->client->status() == QDeclarativeDebugClient::Enabled && objectDebugId != -1) { + if (d->client->state() == QDeclarativeDebugClient::Enabled && objectDebugId != -1) { QByteArray message; QDataStream ds(&message, QIODevice::WriteOnly); ds << QByteArray("RESET_BINDING") << objectDebugId << propertyName; @@ -678,7 +678,7 @@ bool QDeclarativeEngineDebug::setMethodBody(int objectDebugId, const QString &me { Q_D(QDeclarativeEngineDebug); - if (d->client->status() == QDeclarativeDebugClient::Enabled && objectDebugId != -1) { + if (d->client->state() == QDeclarativeDebugClient::Enabled && objectDebugId != -1) { QByteArray message; QDataStream ds(&message, QIODevice::WriteOnly); ds << QByteArray("SET_METHOD_BODY") << objectDebugId << methodName << methodBody; diff --git a/src/declarative/debugger/qdeclarativeenginedebug_p.h b/src/declarative/debugger/qdeclarativeenginedebug_p.h index 7c4a18c7932e06bbaddecfe7b3fed7ea763491ea..5ca2987da39627ec70c3985ea45f88aca84ab774 100644 --- a/src/declarative/debugger/qdeclarativeenginedebug_p.h +++ b/src/declarative/debugger/qdeclarativeenginedebug_p.h @@ -82,12 +82,12 @@ class Q_DECLARATIVE_PRIVATE_EXPORT QDeclarativeEngineDebug : public QObject { Q_OBJECT public: - enum Status { NotConnected, Unavailable, Enabled }; + enum State { NotConnected, Unavailable, Enabled }; explicit QDeclarativeEngineDebug(QDeclarativeDebugConnection *, QObject * = 0); ~QDeclarativeEngineDebug(); - Status status() const; + State state() const; QDeclarativeDebugPropertyWatch *addWatch(const QDeclarativeDebugPropertyReference &, QObject *parent = 0); @@ -120,7 +120,7 @@ public: Q_SIGNALS: void newObjects(); - void statusChanged(Status status); + void stateChanged(State state); private: Q_DECLARE_PRIVATE(QDeclarativeEngineDebug) diff --git a/src/declarative/debugger/qdeclarativeinspectorservice.cpp b/src/declarative/debugger/qdeclarativeinspectorservice.cpp index e0454789c7695b602ce6ede0ec3242d16b787798..94b04985ba401271d5afeba144250e8e919dc57e 100644 --- a/src/declarative/debugger/qdeclarativeinspectorservice.cpp +++ b/src/declarative/debugger/qdeclarativeinspectorservice.cpp @@ -70,29 +70,29 @@ QDeclarativeInspectorService *QDeclarativeInspectorService::instance() void QDeclarativeInspectorService::addView(QObject *view) { m_views.append(view); - updateStatus(); + updateState(); } void QDeclarativeInspectorService::removeView(QObject *view) { m_views.removeAll(view); - updateStatus(); + updateState(); } void QDeclarativeInspectorService::sendMessage(const QByteArray &message) { - if (status() != Enabled) + if (state() != Enabled) return; QDeclarativeDebugService::sendMessage(message); } -void QDeclarativeInspectorService::statusChanged(Status /*status*/) +void QDeclarativeInspectorService::stateChanged(State /*state*/) { - QMetaObject::invokeMethod(this, "updateStatus", Qt::QueuedConnection); + QMetaObject::invokeMethod(this, "updateState", Qt::QueuedConnection); } -void QDeclarativeInspectorService::updateStatus() +void QDeclarativeInspectorService::updateState() { if (m_views.isEmpty()) { if (m_currentInspectorPlugin) { @@ -102,7 +102,7 @@ void QDeclarativeInspectorService::updateStatus() return; } - if (status() == Enabled) { + if (state() == Enabled) { if (m_inspectorPlugins.isEmpty()) loadInspectorPlugins(); diff --git a/src/declarative/debugger/qdeclarativeinspectorservice_p.h b/src/declarative/debugger/qdeclarativeinspectorservice_p.h index 457060dda0bca23a47c1ad3805da56a5a3f309bd..7ed530adc09b60ebe34e6d3f8e3523f2f9fe0e93 100644 --- a/src/declarative/debugger/qdeclarativeinspectorservice_p.h +++ b/src/declarative/debugger/qdeclarativeinspectorservice_p.h @@ -79,12 +79,12 @@ public: void sendMessage(const QByteArray &message); protected: - virtual void statusChanged(Status status); + virtual void stateChanged(State state); virtual void messageReceived(const QByteArray &); private slots: void processMessage(const QByteArray &message); - void updateStatus(); + void updateState(); private: void loadInspectorPlugins(); diff --git a/src/declarative/debugger/qv8debugservice.cpp b/src/declarative/debugger/qv8debugservice.cpp index bcc92964810dc57cbe1adfd06c5db6f97b0811d9..389c465420adaa2e7e3eefef5ceafcc0ed0d1bd2 100644 --- a/src/declarative/debugger/qv8debugservice.cpp +++ b/src/declarative/debugger/qv8debugservice.cpp @@ -124,7 +124,7 @@ QV8DebugService::QV8DebugService(QObject *parent) { Q_D(QV8DebugService); v8ServiceInstancePtr = this; - // wait for statusChanged() -> initialize() + // wait for stateChanged() -> initialize() d->initializeMutex.lock(); if (registerService() == Enabled) { init(); @@ -205,10 +205,10 @@ void QV8DebugService::scheduledDebugBreak(bool schedule) } // executed in the debugger thread -void QV8DebugService::statusChanged(QDeclarativeDebugService::Status newStatus) +void QV8DebugService::stateChanged(QDeclarativeDebugService::State newState) { Q_D(QV8DebugService); - if (newStatus == Enabled) { + if (newState == Enabled) { // execute in GUI thread d->initializeMutex.lock(); QMetaObject::invokeMethod(this, "init", Qt::QueuedConnection); diff --git a/src/declarative/debugger/qv8debugservice_p.h b/src/declarative/debugger/qv8debugservice_p.h index 7f67f70302af295b3eb5bca9f6d8be5d1dc2172a..3f1d1ca17783cb2b3c8fd8e1e41a4176cb1772e1 100644 --- a/src/declarative/debugger/qv8debugservice_p.h +++ b/src/declarative/debugger/qv8debugservice_p.h @@ -87,7 +87,7 @@ private slots: void init(); protected: - void statusChanged(Status newStatus); + void stateChanged(State newState); void messageReceived(const QByteArray &); private: diff --git a/src/declarative/debugger/qv8profilerservice.cpp b/src/declarative/debugger/qv8profilerservice.cpp index 743ee6ec4fd067172db63dc011cfdab62f29e56e..4519fd6eeb1d991849ba378e407e3cdaec46c938 100644 --- a/src/declarative/debugger/qv8profilerservice.cpp +++ b/src/declarative/debugger/qv8profilerservice.cpp @@ -127,14 +127,14 @@ void QV8ProfilerService::initialize() v8ProfilerInstance(); } -void QV8ProfilerService::statusAboutToBeChanged(QDeclarativeDebugService::Status newStatus) +void QV8ProfilerService::stateAboutToBeChanged(QDeclarativeDebugService::State newState) { Q_D(QV8ProfilerService); - if (status() == newStatus) + if (state() == newState) return; - if (status() == Enabled) { + if (state() == Enabled) { foreach (const QString &title, d->m_ongoing) QMetaObject::invokeMethod(this, "stopProfiling", Qt::QueuedConnection, Q_ARG(QString, title)); sendProfilingData(); diff --git a/src/declarative/debugger/qv8profilerservice_p.h b/src/declarative/debugger/qv8profilerservice_p.h index 75589ad839aab4957491cbed172d9e2e90c291ab..706907ae238f364cdf7e01fcccff1afe5472c895 100644 --- a/src/declarative/debugger/qv8profilerservice_p.h +++ b/src/declarative/debugger/qv8profilerservice_p.h @@ -104,7 +104,7 @@ public slots: void sendProfilingData(); protected: - void statusAboutToBeChanged(Status status); + void stateAboutToBeChanged(State state); void messageReceived(const QByteArray &); private: diff --git a/tests/auto/declarative/debugger/qdebugmessageservice/tst_qdebugmessageservice.cpp b/tests/auto/declarative/debugger/qdebugmessageservice/tst_qdebugmessageservice.cpp index 8b38d26127e875d6fe4cdca1f877b7e8634cde77..bf5c139730f2013a948ff44c11f000abd0ca2a4b 100644 --- a/tests/auto/declarative/debugger/qdebugmessageservice/tst_qdebugmessageservice.cpp +++ b/tests/auto/declarative/debugger/qdebugmessageservice/tst_qdebugmessageservice.cpp @@ -104,7 +104,7 @@ public: protected: //inherited from QDeclarativeDebugClient - void statusChanged(Status status); + void stateChanged(State state); void messageReceived(const QByteArray &data); signals: @@ -112,9 +112,9 @@ signals: void debugOutput(); }; -void QDeclarativeDebugMsgClient::statusChanged(Status status) +void QDeclarativeDebugMsgClient::stateChanged(State state) { - if (status == Enabled) { + if (state == Enabled) { emit enabled(); } } diff --git a/tests/auto/declarative/debugger/qdeclarativedebugclient/tst_qdeclarativedebugclient.cpp b/tests/auto/declarative/debugger/qdeclarativedebugclient/tst_qdeclarativedebugclient.cpp index 1a5aeb94580a2ccca9ace622725c86d6354727c0..e059c7617b4a732f1186529cbc26bdceff14736b 100644 --- a/tests/auto/declarative/debugger/qdeclarativedebugclient/tst_qdeclarativedebugclient.cpp +++ b/tests/auto/declarative/debugger/qdeclarativedebugclient/tst_qdeclarativedebugclient.cpp @@ -63,7 +63,7 @@ private slots: void initTestCase(); void name(); - void status(); + void state(); void sendMessage(); void parallelConnect(); void sequentialConnect(); @@ -92,7 +92,7 @@ void tst_QDeclarativeDebugClient::initTestCase() QVERIFY(m_conn->isConnected()); QTRY_VERIFY(QDeclarativeDebugService::hasDebuggingClient()); - QTRY_COMPARE(client.status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(client.state(), QDeclarativeDebugClient::Enabled); } void tst_QDeclarativeDebugClient::name() @@ -103,33 +103,33 @@ void tst_QDeclarativeDebugClient::name() QCOMPARE(client.name(), name); } -void tst_QDeclarativeDebugClient::status() +void tst_QDeclarativeDebugClient::state() { { QDeclarativeDebugConnection dummyConn; - QDeclarativeDebugClient client("tst_QDeclarativeDebugClient::status()", &dummyConn); - QCOMPARE(client.status(), QDeclarativeDebugClient::NotConnected); + QDeclarativeDebugClient client("tst_QDeclarativeDebugClient::state()", &dummyConn); + QCOMPARE(client.state(), QDeclarativeDebugClient::NotConnected); QCOMPARE(client.serviceVersion(), -1.0f); } - QDeclarativeDebugTestClient client("tst_QDeclarativeDebugClient::status()", m_conn); - QCOMPARE(client.status(), QDeclarativeDebugClient::Unavailable); + QDeclarativeDebugTestClient client("tst_QDeclarativeDebugClient::state()", m_conn); + QCOMPARE(client.state(), QDeclarativeDebugClient::Unavailable); { - QDeclarativeDebugTestService service("tst_QDeclarativeDebugClient::status()", 2); - QTRY_COMPARE(client.status(), QDeclarativeDebugClient::Enabled); + QDeclarativeDebugTestService service("tst_QDeclarativeDebugClient::state()", 2); + QTRY_COMPARE(client.state(), QDeclarativeDebugClient::Enabled); QCOMPARE(client.serviceVersion(), 2.0f); } - QTRY_COMPARE(client.status(), QDeclarativeDebugClient::Unavailable); + QTRY_COMPARE(client.state(), QDeclarativeDebugClient::Unavailable); // duplicate plugin name - QTest::ignoreMessage(QtWarningMsg, "QDeclarativeDebugClient: Conflicting plugin name \"tst_QDeclarativeDebugClient::status()\" "); - QDeclarativeDebugClient client2("tst_QDeclarativeDebugClient::status()", m_conn); - QCOMPARE(client2.status(), QDeclarativeDebugClient::NotConnected); + QTest::ignoreMessage(QtWarningMsg, "QDeclarativeDebugClient: Conflicting plugin name \"tst_QDeclarativeDebugClient::state()\" "); + QDeclarativeDebugClient client2("tst_QDeclarativeDebugClient::state()", m_conn); + QCOMPARE(client2.state(), QDeclarativeDebugClient::NotConnected); - QDeclarativeDebugClient client3("tst_QDeclarativeDebugClient::status3()", 0); - QCOMPARE(client3.status(), QDeclarativeDebugClient::NotConnected); + QDeclarativeDebugClient client3("tst_QDeclarativeDebugClient::state3()", 0); + QCOMPARE(client3.state(), QDeclarativeDebugClient::NotConnected); } void tst_QDeclarativeDebugClient::sendMessage() @@ -139,7 +139,7 @@ void tst_QDeclarativeDebugClient::sendMessage() QByteArray msg = "hello!"; - QTRY_COMPARE(client.status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(client.state(), QDeclarativeDebugClient::Enabled); client.sendMessage(msg); QByteArray resp = client.waitForResponse(); @@ -175,7 +175,7 @@ void tst_QDeclarativeDebugClient::sequentialConnect() QTest::ignoreMessage(QtWarningMsg, "QDeclarativeDebugServer: Connection established"); QVERIFY(connection2.waitForConnected()); QVERIFY(connection2.isConnected()); - QTRY_VERIFY(client2.status() == QDeclarativeDebugClient::Enabled); + QTRY_VERIFY(client2.state() == QDeclarativeDebugClient::Enabled); } int main(int argc, char *argv[]) diff --git a/tests/auto/declarative/debugger/qdeclarativedebugjs/tst_qdeclarativedebugjs.cpp b/tests/auto/declarative/debugger/qdeclarativedebugjs/tst_qdeclarativedebugjs.cpp index 03aeef165b2781e0bbb11d1d98b74741b7f71bcf..7d57c8eda2f7e4dca65864fad8749932bb2388c7 100644 --- a/tests/auto/declarative/debugger/qdeclarativedebugjs/tst_qdeclarativedebugjs.cpp +++ b/tests/auto/declarative/debugger/qdeclarativedebugjs/tst_qdeclarativedebugjs.cpp @@ -293,7 +293,7 @@ public: protected: //inherited from QDeclarativeDebugClient - void statusChanged(Status status); + void stateChanged(State state); void messageReceived(const QByteArray &data); signals: @@ -879,9 +879,9 @@ void QJSDebugClient::listBreakpoints() sendMessage(packMessage(V8REQUEST, json.toString().toUtf8())); } -void QJSDebugClient::statusChanged(Status status) +void QJSDebugClient::stateChanged(State state) { - if (status == Enabled) { + if (state == Enabled) { flushSendBuffer(); emit enabled(); } @@ -957,7 +957,7 @@ void QJSDebugClient::messageReceived(const QByteArray &data) void QJSDebugClient::sendMessage(const QByteArray &msg) { - if (status() == Enabled) { + if (state() == Enabled) { QDeclarativeDebugClient::sendMessage(msg); } else { sendBuffer.append(msg); diff --git a/tests/auto/declarative/debugger/qdeclarativedebugservice/tst_qdeclarativedebugservice.cpp b/tests/auto/declarative/debugger/qdeclarativedebugservice/tst_qdeclarativedebugservice.cpp index 89cea1692e4b6a4cf5cec22c44f06f8c1700ecfc..c38b7854e012caa72602da10b8c8023523c2c1c3 100644 --- a/tests/auto/declarative/debugger/qdeclarativedebugservice/tst_qdeclarativedebugservice.cpp +++ b/tests/auto/declarative/debugger/qdeclarativedebugservice/tst_qdeclarativedebugservice.cpp @@ -67,7 +67,7 @@ private slots: void name(); void version(); - void status(); + void state(); void sendMessage(); void idForObject(); void objectForId(); @@ -112,23 +112,23 @@ void tst_QDeclarativeDebugService::version() QCOMPARE(service.version(), 2.0f); } -void tst_QDeclarativeDebugService::status() +void tst_QDeclarativeDebugService::state() { - QDeclarativeDebugTestService service("tst_QDeclarativeDebugService::status()"); - QCOMPARE(service.status(), QDeclarativeDebugService::Unavailable); + QDeclarativeDebugTestService service("tst_QDeclarativeDebugService::state()"); + QCOMPARE(service.state(), QDeclarativeDebugService::Unavailable); { - QDeclarativeDebugTestClient client("tst_QDeclarativeDebugService::status()", m_conn); - QTRY_COMPARE(client.status(), QDeclarativeDebugClient::Enabled); - QTRY_COMPARE(service.status(), QDeclarativeDebugService::Enabled); + QDeclarativeDebugTestClient client("tst_QDeclarativeDebugService::state()", m_conn); + QTRY_COMPARE(client.state(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(service.state(), QDeclarativeDebugService::Enabled); } - QTRY_COMPARE(service.status(), QDeclarativeDebugService::Unavailable); + QTRY_COMPARE(service.state(), QDeclarativeDebugService::Unavailable); - QTest::ignoreMessage(QtWarningMsg, "QDeclarativeDebugService: Conflicting plugin name \"tst_QDeclarativeDebugService::status()\" "); - QDeclarativeDebugTestService duplicate("tst_QDeclarativeDebugService::status()"); - QCOMPARE(duplicate.status(), QDeclarativeDebugService::NotConnected); + QTest::ignoreMessage(QtWarningMsg, "QDeclarativeDebugService: Conflicting plugin name \"tst_QDeclarativeDebugService::state()\" "); + QDeclarativeDebugTestService duplicate("tst_QDeclarativeDebugService::state()"); + QCOMPARE(duplicate.state(), QDeclarativeDebugService::NotConnected); } void tst_QDeclarativeDebugService::sendMessage() @@ -138,8 +138,8 @@ void tst_QDeclarativeDebugService::sendMessage() QByteArray msg = "hello!"; - QTRY_COMPARE(client.status(), QDeclarativeDebugClient::Enabled); - QTRY_COMPARE(service.status(), QDeclarativeDebugService::Enabled); + QTRY_COMPARE(client.state(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(service.state(), QDeclarativeDebugService::Enabled); client.sendMessage(msg); QByteArray resp = client.waitForResponse(); diff --git a/tests/auto/declarative/debugger/qdeclarativedebugtrace/tst_qdeclarativedebugtrace.cpp b/tests/auto/declarative/debugger/qdeclarativedebugtrace/tst_qdeclarativedebugtrace.cpp index e0c8af7181c288a007f1aaa940b634966d805b5e..f0a660c1465e27b28798121d0d26b27d192747c4 100644 --- a/tests/auto/declarative/debugger/qdeclarativedebugtrace/tst_qdeclarativedebugtrace.cpp +++ b/tests/auto/declarative/debugger/qdeclarativedebugtrace/tst_qdeclarativedebugtrace.cpp @@ -61,7 +61,7 @@ public: QList<QDeclarativeDebugData> traceMessages; - void setTraceStatus(bool enabled) { + void setTraceState(bool enabled) { QByteArray message; QDataStream stream(&message, QIODevice::WriteOnly); stream << enabled; @@ -216,10 +216,10 @@ void tst_QDeclarativeDebugTrace::cleanup() void tst_QDeclarativeDebugTrace::blockingConnectWithTraceEnabled() { connect(true, "test.qml"); - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); - m_client->setTraceStatus(true); - m_client->setTraceStatus(false); + m_client->setTraceState(true); + m_client->setTraceState(false); if (!QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(complete()))) { QString failMsg = QString("No trace received in time. App output: \n%1\n").arg(m_process->output()); @@ -239,11 +239,11 @@ void tst_QDeclarativeDebugTrace::blockingConnectWithTraceEnabled() void tst_QDeclarativeDebugTrace::blockingConnectWithTraceDisabled() { connect(true, "test.qml"); - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); - m_client->setTraceStatus(false); - m_client->setTraceStatus(true); - m_client->setTraceStatus(false); + m_client->setTraceState(false); + m_client->setTraceState(true); + m_client->setTraceState(false); if (!QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(complete()))) { QString failMsg = QString("No trace received in time. App output: \n%1\n").arg(m_process->output()); @@ -264,10 +264,10 @@ void tst_QDeclarativeDebugTrace::blockingConnectWithTraceDisabled() void tst_QDeclarativeDebugTrace::nonBlockingConnect() { connect(false, "test.qml"); - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); - m_client->setTraceStatus(true); - m_client->setTraceStatus(false); + m_client->setTraceState(true); + m_client->setTraceState(false); if (!QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(complete()))) { QString failMsg = QString("No trace received in time. App output: \n%1\n").arg(m_process->output()); @@ -286,9 +286,9 @@ void tst_QDeclarativeDebugTrace::nonBlockingConnect() void tst_QDeclarativeDebugTrace::profileOnExit() { connect(true, "exit.qml"); - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); - m_client->setTraceStatus(true); + m_client->setTraceState(true); if (!QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(complete()))) { QString failMsg diff --git a/tests/auto/declarative/debugger/qdeclarativeenginedebug/tst_qdeclarativeenginedebug.cpp b/tests/auto/declarative/debugger/qdeclarativeenginedebug/tst_qdeclarativeenginedebug.cpp index e13e32223a0661a7d705818099c531036c9c0be6..098ac90ca5b753484796aa5a6b6ec1048ca213c9 100644 --- a/tests/auto/declarative/debugger/qdeclarativeenginedebug/tst_qdeclarativeenginedebug.cpp +++ b/tests/auto/declarative/debugger/qdeclarativeenginedebug/tst_qdeclarativeenginedebug.cpp @@ -387,7 +387,7 @@ void tst_QDeclarativeEngineDebug::initTestCase() QVERIFY(ok); QTRY_VERIFY(QDeclarativeDebugService::hasDebuggingClient()); m_dbg = new QDeclarativeEngineDebug(m_conn, this); - QTRY_VERIFY(m_dbg->status() == QDeclarativeEngineDebug::Enabled); + QTRY_VERIFY(m_dbg->state() == QDeclarativeEngineDebug::Enabled); } void tst_QDeclarativeEngineDebug::cleanupTestCase() diff --git a/tests/auto/declarative/debugger/qdeclarativeinspector/tst_qdeclarativeinspector.cpp b/tests/auto/declarative/debugger/qdeclarativeinspector/tst_qdeclarativeinspector.cpp index b03faccfdc50eb979e78b77b1d66f3a1f2d3ab7e..4d7e57f4d4c12bc2a0a61f6bf027ca42e472109b 100644 --- a/tests/auto/declarative/debugger/qdeclarativeinspector/tst_qdeclarativeinspector.cpp +++ b/tests/auto/declarative/debugger/qdeclarativeinspector/tst_qdeclarativeinspector.cpp @@ -165,12 +165,12 @@ void tst_QDeclarativeInspector::cleanup() void tst_QDeclarativeInspector::connect() { - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); } void tst_QDeclarativeInspector::showAppOnTop() { - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); m_client->setShowAppOnTop(true); QVERIFY(QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(showAppOnTopChanged()))); diff --git a/tests/auto/declarative/debugger/qv8profilerservice/tst_qv8profilerservice.cpp b/tests/auto/declarative/debugger/qv8profilerservice/tst_qv8profilerservice.cpp index 2556e41e4fdd1341d937d99da44dd5ed9b97675f..3ec92f9987d4b6414d90643abfa7f40da2dc9712 100644 --- a/tests/auto/declarative/debugger/qv8profilerservice/tst_qv8profilerservice.cpp +++ b/tests/auto/declarative/debugger/qv8profilerservice/tst_qv8profilerservice.cpp @@ -201,7 +201,7 @@ void tst_QV8ProfilerService::cleanup() void tst_QV8ProfilerService::blockingConnectWithTraceEnabled() { connect(true, "test.qml"); - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); m_client->startProfiling(""); m_client->stopProfiling(""); @@ -215,7 +215,7 @@ void tst_QV8ProfilerService::blockingConnectWithTraceEnabled() void tst_QV8ProfilerService::blockingConnectWithTraceDisabled() { connect(true, "test.qml"); - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); m_client->stopProfiling(""); if (QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(complete()), 1000)) { @@ -235,7 +235,7 @@ void tst_QV8ProfilerService::blockingConnectWithTraceDisabled() void tst_QV8ProfilerService::nonBlockingConnect() { connect(false, "test.qml"); - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); m_client->startProfiling(""); m_client->stopProfiling(""); @@ -249,7 +249,7 @@ void tst_QV8ProfilerService::nonBlockingConnect() void tst_QV8ProfilerService::snapshot() { connect(false, "test.qml"); - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); m_client->takeSnapshot(); if (!QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(snapshot()))) { @@ -262,7 +262,7 @@ void tst_QV8ProfilerService::snapshot() void tst_QV8ProfilerService::profileOnExit() { connect(true, "exit.qml"); - QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); + QTRY_COMPARE(m_client->state(), QDeclarativeDebugClient::Enabled); m_client->startProfiling(""); diff --git a/tests/auto/declarative/debugger/shared/debugutil.cpp b/tests/auto/declarative/debugger/shared/debugutil.cpp index 14bf68285d821cef55781a85a1bf749f2534718f..fcac1bc61d057f0f15f6354552eb7e76717943fa 100644 --- a/tests/auto/declarative/debugger/shared/debugutil.cpp +++ b/tests/auto/declarative/debugger/shared/debugutil.cpp @@ -69,9 +69,9 @@ void QDeclarativeDebugTestService::messageReceived(const QByteArray &ba) sendMessage(ba); } -void QDeclarativeDebugTestService::statusChanged(Status) +void QDeclarativeDebugTestService::stateChanged(State) { - emit statusHasChanged(); + emit stateHasChanged(); } @@ -91,10 +91,10 @@ QByteArray QDeclarativeDebugTestClient::waitForResponse() return lastMsg; } -void QDeclarativeDebugTestClient::statusChanged(Status stat) +void QDeclarativeDebugTestClient::stateChanged(State stat) { - QCOMPARE(stat, status()); - emit statusHasChanged(); + QCOMPARE(stat, state()); + emit stateHasChanged(); } void QDeclarativeDebugTestClient::messageReceived(const QByteArray &ba) diff --git a/tests/auto/declarative/debugger/shared/debugutil_p.h b/tests/auto/declarative/debugger/shared/debugutil_p.h index aecd656a07a34323c7420170c94b6c723da03d4b..520cb11a5aabd551c7a0cff2512f047901aa87f5 100644 --- a/tests/auto/declarative/debugger/shared/debugutil_p.h +++ b/tests/auto/declarative/debugger/shared/debugutil_p.h @@ -67,11 +67,11 @@ public: QDeclarativeDebugTestService(const QString &s, float version = 1, QObject *parent = 0); signals: - void statusHasChanged(); + void stateHasChanged(); protected: virtual void messageReceived(const QByteArray &ba); - virtual void statusChanged(Status status); + virtual void stateChanged(State state); }; class QDeclarativeDebugTestClient : public QDeclarativeDebugClient @@ -83,11 +83,11 @@ public: QByteArray waitForResponse(); signals: - void statusHasChanged(); + void stateHasChanged(); void serverMessage(const QByteArray &); protected: - virtual void statusChanged(Status status); + virtual void stateChanged(State state); virtual void messageReceived(const QByteArray &ba); private: