aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@theqtcompany.com>2015-07-13 15:09:42 +0200
committerUlf Hermann <ulf.hermann@theqtcompany.com>2015-07-21 08:33:27 +0000
commit4d581ceb1d589d603224733275995d14c795a8c9 (patch)
treebb59d15b92ea1ebdc71ec38f6cf62c7a1f79d8dc /src/plugins
parent134d980a7fcf61c5440019bcfb3fdfc39c3f5f3c (diff)
Simplify object/id lookup in QQmlDebugService
By tracking object destruction we can avoid looping over all cached objects to find out which ones are still OK and we don't have to manually clear the cache anymore. Looking up objects by source location is specific to the engine debug service and should be done there. Change-Id: I7dab73a7bf9c17087784f1bd9c5aef513b31e2c1 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/qmltooling/qmldbg_qtquick2/qquickviewinspector.cpp2
-rw-r--r--src/plugins/qmltooling/shared/abstractviewinspector.cpp1
2 files changed, 0 insertions, 3 deletions
diff --git a/src/plugins/qmltooling/qmldbg_qtquick2/qquickviewinspector.cpp b/src/plugins/qmltooling/qmldbg_qtquick2/qquickviewinspector.cpp
index 9255e49364..c5cf6c31d4 100644
--- a/src/plugins/qmltooling/qmldbg_qtquick2/qquickviewinspector.cpp
+++ b/src/plugins/qmltooling/qmldbg_qtquick2/qquickviewinspector.cpp
@@ -315,8 +315,6 @@ void QQuickViewInspector::reloadQmlFile(const QHash<QString, QByteArray> &change
// Reset the selection since we are reloading the main qml
setSelectedItems(QList<QQuickItem *>());
- QQmlDebugService::clearObjectsFromHash();
-
QHash<QUrl, QByteArray> debugCache;
foreach (const QString &str, changesHash.keys())
diff --git a/src/plugins/qmltooling/shared/abstractviewinspector.cpp b/src/plugins/qmltooling/shared/abstractviewinspector.cpp
index 06f622a65e..b23cff9a78 100644
--- a/src/plugins/qmltooling/shared/abstractviewinspector.cpp
+++ b/src/plugins/qmltooling/shared/abstractviewinspector.cpp
@@ -260,7 +260,6 @@ void AbstractViewInspector::onQmlObjectDestroyed(QObject *object)
return;
QPair<int, int> ids = m_hashObjectsTobeDestroyed.take(object);
- QQmlDebugService::removeInvalidObjectsFromHash();
QByteArray response;