diff options
Diffstat (limited to 'src/declarative/debugger/qdeclarativeenginedebug.cpp')
-rw-r--r-- | src/declarative/debugger/qdeclarativeenginedebug.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/declarative/debugger/qdeclarativeenginedebug.cpp b/src/declarative/debugger/qdeclarativeenginedebug.cpp index 3232eeab..2eabc0ba 100644 --- a/src/declarative/debugger/qdeclarativeenginedebug.cpp +++ b/src/declarative/debugger/qdeclarativeenginedebug.cpp @@ -932,6 +932,20 @@ QList<QDeclarativeDebugObjectReference> QDeclarativeDebugObjectReference::childr return m_children; } +QDeclarativeDebugObjectReference QDeclarativeDebugObjectReference::findChildByClassName(const QString &className, QDeclarativeDebugObjectReference after) const +{ + foreach (const QDeclarativeDebugObjectReference &child, m_children) + if (after.debugId() != -1) { + if (child.debugId() == after.debugId()) + after = QDeclarativeDebugObjectReference(); + } else { + if (child.className() == className) + return child; + } + + return QDeclarativeDebugObjectReference(); +} + QDeclarativeDebugContextReference::QDeclarativeDebugContextReference() : m_debugId(-1) { |