diff options
author | Ulf Hermann <ulf.hermann@theqtcompany.com> | 2015-07-13 16:13:00 +0200 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@theqtcompany.com> | 2015-07-29 14:35:54 +0000 |
commit | db90054b186317da4e363c64207c0156d9d73da5 (patch) | |
tree | 3c9c7fd5d58ace0bb5e03e7fb67dae8661e08902 /src/qml/debugger | |
parent | 3f3de3b9b762ecc2799a3575b97a2b172fcbc79a (diff) |
Remove static proxy methods from QQmlDebugService
They all internally map to one-liners and just add to binary size and
complexity. Especially, the most used one, isDebuggingEnabled(), simply
checks if there is a QQmlDebugServer::instance().
Change-Id: Ib269928e08506894d933f6696e34ff0d3acb048b
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Diffstat (limited to 'src/qml/debugger')
-rw-r--r-- | src/qml/debugger/qqmlconfigurabledebugservice.cpp | 4 | ||||
-rw-r--r-- | src/qml/debugger/qqmldebugservice.cpp | 17 | ||||
-rw-r--r-- | src/qml/debugger/qqmldebugservice_p.h | 4 |
3 files changed, 3 insertions, 22 deletions
diff --git a/src/qml/debugger/qqmlconfigurabledebugservice.cpp b/src/qml/debugger/qqmlconfigurabledebugservice.cpp index c63910efc5..808a0f104f 100644 --- a/src/qml/debugger/qqmlconfigurabledebugservice.cpp +++ b/src/qml/debugger/qqmlconfigurabledebugservice.cpp @@ -33,6 +33,7 @@ #include "qqmlconfigurabledebugservice_p.h" #include "qqmlconfigurabledebugservice_p_p.h" +#include "qqmldebugserver_p.h" QT_BEGIN_NAMESPACE @@ -55,7 +56,8 @@ void QQmlConfigurableDebugService::init() Q_D(QQmlConfigurableDebugService); QMutexLocker lock(&d->configMutex); // If we're not enabled or not blocking, don't wait for configuration - d->waitingForConfiguration = (registerService() == Enabled && blockingMode()); + d->waitingForConfiguration = (registerService() == Enabled && + QQmlDebugServer::instance()->blockingMode()); } void QQmlConfigurableDebugService::stopWaiting() diff --git a/src/qml/debugger/qqmldebugservice.cpp b/src/qml/debugger/qqmldebugservice.cpp index da9300477b..c70ea10175 100644 --- a/src/qml/debugger/qqmldebugservice.cpp +++ b/src/qml/debugger/qqmldebugservice.cpp @@ -159,23 +159,6 @@ const QHash<int, QObject *> &QQmlDebugService::objectsForIds() return objectReferenceHash()->ids; } -bool QQmlDebugService::isDebuggingEnabled() -{ - return QQmlDebugServer::instance() != 0; -} - -bool QQmlDebugService::hasDebuggingClient() -{ - return QQmlDebugServer::instance() != 0 - && QQmlDebugServer::instance()->hasDebuggingClient(); -} - -bool QQmlDebugService::blockingMode() -{ - return QQmlDebugServer::instance() != 0 - && QQmlDebugServer::instance()->blockingMode(); -} - QString QQmlDebugService::objectToString(QObject *obj) { if(!obj) diff --git a/src/qml/debugger/qqmldebugservice_p.h b/src/qml/debugger/qqmldebugservice_p.h index 3574f68b7f..f25bb48e05 100644 --- a/src/qml/debugger/qqmldebugservice_p.h +++ b/src/qml/debugger/qqmldebugservice_p.h @@ -80,10 +80,6 @@ public: static QString objectToString(QObject *obj); - static bool isDebuggingEnabled(); - static bool hasDebuggingClient(); - static bool blockingMode(); - protected: explicit QQmlDebugService(const QString &, float version, QObject *parent = 0); QQmlDebugService(QQmlDebugServicePrivate &dd, QObject *parent = 0); |