aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorFrederik Gladhorn <frederik.gladhorn@digia.com>2013-05-28 15:06:25 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-05-28 19:35:13 +0200
commit17b4cf5e49b95f322b5dcb39f4c122b17fd3c39f (patch)
treecc00e380288aaebed5675647cc5e85c5121b74cb /src/plugins
parent43484528552cb2ba3dc1dabfcce22ed40bf4f8db (diff)
Accessibility: Fix crash when accessing accessible children.
The window would create new child interfaces every time it's children are queried. Instead properly use the crash. Task-number: QTBUG-31417 Change-Id: Ifc7bbdbdb9a506fe04a348fba643f1d52a6157e7 Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/accessible/quick/qaccessiblequickview.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/plugins/accessible/quick/qaccessiblequickview.cpp b/src/plugins/accessible/quick/qaccessiblequickview.cpp
index b85f23c48b..1240b2ef4c 100644
--- a/src/plugins/accessible/quick/qaccessiblequickview.cpp
+++ b/src/plugins/accessible/quick/qaccessiblequickview.cpp
@@ -81,10 +81,8 @@ QAccessibleInterface *QAccessibleQuickWindow::parent() const
QAccessibleInterface *QAccessibleQuickWindow::child(int index) const
{
- if (index == 0) {
- if (QQuickItem *declarativeRoot = rootItem())
- return new QAccessibleQuickItem(declarativeRoot);
- }
+ if (index == 0)
+ return QAccessible::queryAccessibleInterface(rootItem());
return 0;
}