diff options
author | Aaron Kennedy <aaron.kennedy@nokia.com> | 2009-07-13 07:44:29 (GMT) |
---|---|---|
committer | Aaron Kennedy <aaron.kennedy@nokia.com> | 2009-07-13 07:48:21 (GMT) |
commit | 9eca9e028884fb82d97e284826faa7965af356bd (patch) | |
tree | ab410246de056403fcc8bef374af0898cb77b47f /src/declarative/debugger | |
parent | b95f28940857332983f176a8e0d356e3e67e5acc (diff) | |
download | Qt-9eca9e028884fb82d97e284826faa7965af356bd.zip Qt-9eca9e028884fb82d97e284826faa7965af356bd.tar.gz Qt-9eca9e028884fb82d97e284826faa7965af356bd.tar.bz2 |
Rename QmlDebugServerPlugin -> QmlDebugService
Diffstat (limited to 'src/declarative/debugger')
-rw-r--r-- | src/declarative/debugger/debugger.pri | 4 | ||||
-rw-r--r-- | src/declarative/debugger/qmldebugservice.cpp (renamed from src/declarative/debugger/qmldebugserver.cpp) | 56 | ||||
-rw-r--r-- | src/declarative/debugger/qmldebugservice.h (renamed from src/declarative/debugger/qmldebugserver.h) | 16 |
3 files changed, 38 insertions, 38 deletions
diff --git a/src/declarative/debugger/debugger.pri b/src/declarative/debugger/debugger.pri index 33076ea..82746fc 100644 --- a/src/declarative/debugger/debugger.pri +++ b/src/declarative/debugger/debugger.pri @@ -1,11 +1,11 @@ SOURCES += debugger/qmldebuggerstatus.cpp \ debugger/qpacketprotocol.cpp \ - debugger/qmldebugserver.cpp \ + debugger/qmldebugservice.cpp \ debugger/qmldebugclient.cpp \ debugger/qmldebug.cpp HEADERS += debugger/qmldebuggerstatus.h \ debugger/qpacketprotocol.h \ - debugger/qmldebugserver.h \ + debugger/qmldebugservice.h \ debugger/qmldebugclient.h \ debugger/qmldebug.h diff --git a/src/declarative/debugger/qmldebugserver.cpp b/src/declarative/debugger/qmldebugservice.cpp index ddfb88a..9725494 100644 --- a/src/declarative/debugger/qmldebugserver.cpp +++ b/src/declarative/debugger/qmldebugservice.cpp @@ -39,7 +39,7 @@ ** ****************************************************************************/ -#include "qmldebugserver.h" +#include "qmldebugservice.h" #include <QtCore/qdebug.h> #include <QtNetwork/qtcpserver.h> #include <QtNetwork/qtcpsocket.h> @@ -62,8 +62,8 @@ private slots: void readyRead(); private: - friend class QmlDebugServerPlugin; - friend class QmlDebugServerPluginPrivate; + friend class QmlDebugService; + friend class QmlDebugServicePrivate; QmlDebugServer(int); }; @@ -76,15 +76,15 @@ public: QTcpSocket *connection; QPacketProtocol *protocol; - QHash<QString, QmlDebugServerPlugin *> plugins; + QHash<QString, QmlDebugService *> plugins; QStringList enabledPlugins; }; -class QmlDebugServerPluginPrivate : public QObjectPrivate +class QmlDebugServicePrivate : public QObjectPrivate { - Q_DECLARE_PUBLIC(QmlDebugServerPlugin) + Q_DECLARE_PUBLIC(QmlDebugService) public: - QmlDebugServerPluginPrivate(); + QmlDebugServicePrivate(); QString name; QmlDebugServer *server; @@ -184,7 +184,7 @@ void QmlDebugServer::readyRead() // Enable if (!d->enabledPlugins.contains(plugin)) { d->enabledPlugins.append(plugin); - QHash<QString, QmlDebugServerPlugin *>::Iterator iter = + QHash<QString, QmlDebugService *>::Iterator iter = d->plugins.find(plugin); if (iter != d->plugins.end()) (*iter)->enabledChanged(true); @@ -194,7 +194,7 @@ void QmlDebugServer::readyRead() // Disable if (d->enabledPlugins.contains(plugin)) { d->enabledPlugins.removeAll(plugin); - QHash<QString, QmlDebugServerPlugin *>::Iterator iter = + QHash<QString, QmlDebugService *>::Iterator iter = d->plugins.find(plugin); if (iter != d->plugins.end()) (*iter)->enabledChanged(false); @@ -207,7 +207,7 @@ void QmlDebugServer::readyRead() QByteArray message; pack >> message; - QHash<QString, QmlDebugServerPlugin *>::Iterator iter = + QHash<QString, QmlDebugService *>::Iterator iter = d->plugins.find(name); if (iter == d->plugins.end()) { qWarning() << "QmlDebugServer: Message received for missing plugin" << name; @@ -218,15 +218,15 @@ void QmlDebugServer::readyRead() } } -QmlDebugServerPluginPrivate::QmlDebugServerPluginPrivate() +QmlDebugServicePrivate::QmlDebugServicePrivate() : server(0) { } -QmlDebugServerPlugin::QmlDebugServerPlugin(const QString &name, QObject *parent) -: QObject(*(new QmlDebugServerPluginPrivate), parent) +QmlDebugService::QmlDebugService(const QString &name, QObject *parent) +: QObject(*(new QmlDebugServicePrivate), parent) { - Q_D(QmlDebugServerPlugin); + Q_D(QmlDebugService); d->name = name; d->server = QmlDebugServer::instance(); @@ -234,22 +234,22 @@ QmlDebugServerPlugin::QmlDebugServerPlugin(const QString &name, QObject *parent) return; if (d->server->d_func()->plugins.contains(name)) { - qWarning() << "QmlDebugServerPlugin: Conflicting plugin name" << name; + qWarning() << "QmlDebugService: Conflicting plugin name" << name; d->server = 0; } else { d->server->d_func()->plugins.insert(name, this); } } -QString QmlDebugServerPlugin::name() const +QString QmlDebugService::name() const { - Q_D(const QmlDebugServerPlugin); + Q_D(const QmlDebugService); return d->name; } -bool QmlDebugServerPlugin::isEnabled() const +bool QmlDebugService::isEnabled() const { - Q_D(const QmlDebugServerPlugin); + Q_D(const QmlDebugService); return (d->server && d->server->d_func()->enabledPlugins.contains(d->name)); } @@ -279,7 +279,7 @@ Q_GLOBAL_STATIC(ObjectReferenceHash, objectReferenceHash); Returns a unique id for \a object. Calling this method multiple times for the same object will return the same id. */ -int QmlDebugServerPlugin::idForObject(QObject *object) +int QmlDebugService::idForObject(QObject *object) { if (!object) return -1; @@ -312,7 +312,7 @@ int QmlDebugServerPlugin::idForObject(QObject *object) assigned an id, through idForObject(), then 0 is returned. If the object has been destroyed, 0 is returned. */ -QObject *QmlDebugServerPlugin::objectForId(int id) +QObject *QmlDebugService::objectForId(int id) { ObjectReferenceHash *hash = objectReferenceHash(); @@ -334,12 +334,12 @@ QObject *QmlDebugServerPlugin::objectForId(int id) } } -bool QmlDebugServerPlugin::isDebuggingEnabled() +bool QmlDebugService::isDebuggingEnabled() { return QmlDebugServer::instance() != 0; } -QString QmlDebugServerPlugin::objectToString(QObject *obj) +QString QmlDebugService::objectToString(QObject *obj) { if(!obj) return QLatin1String("NULL"); @@ -354,9 +354,9 @@ QString QmlDebugServerPlugin::objectToString(QObject *obj) return rv; } -void QmlDebugServerPlugin::sendMessage(const QByteArray &message) +void QmlDebugService::sendMessage(const QByteArray &message) { - Q_D(QmlDebugServerPlugin); + Q_D(QmlDebugService); if (!d->server || !d->server->d_func()->connection) return; @@ -367,14 +367,14 @@ void QmlDebugServerPlugin::sendMessage(const QByteArray &message) d->server->d_func()->connection->flush(); } -void QmlDebugServerPlugin::enabledChanged(bool) +void QmlDebugService::enabledChanged(bool) { } -void QmlDebugServerPlugin::messageReceived(const QByteArray &) +void QmlDebugService::messageReceived(const QByteArray &) { } QT_END_NAMESPACE -#include "qmldebugserver.moc" +#include "qmldebugservice.moc" diff --git a/src/declarative/debugger/qmldebugserver.h b/src/declarative/debugger/qmldebugservice.h index b15ee2e..b1344c4 100644 --- a/src/declarative/debugger/qmldebugserver.h +++ b/src/declarative/debugger/qmldebugservice.h @@ -39,8 +39,8 @@ ** ****************************************************************************/ -#ifndef QMLDEBUGSERVER_H -#define QMLDEBUGSERVER_H +#ifndef QMLDEBUGSERVICE_H +#define QMLDEBUGSERVICE_H #include <QtCore/qobject.h> @@ -48,14 +48,14 @@ QT_BEGIN_HEADER QT_BEGIN_NAMESPACE -class QmlDebugServerPluginPrivate; -class QmlDebugServerPlugin : public QObject +class QmlDebugServicePrivate; +class QmlDebugService : public QObject { Q_OBJECT - Q_DECLARE_PRIVATE(QmlDebugServerPlugin) - Q_DISABLE_COPY(QmlDebugServerPlugin) + Q_DECLARE_PRIVATE(QmlDebugService) + Q_DISABLE_COPY(QmlDebugService) public: - QmlDebugServerPlugin(const QString &, QObject *parent = 0); + QmlDebugService(const QString &, QObject *parent = 0); QString name() const; @@ -82,5 +82,5 @@ QT_END_NAMESPACE QT_END_HEADER -#endif // QMLDEBUGSERVER_H +#endif // QMLDEBUGSERVICE_H |