diff options
author | Frederik Gladhorn <frederik.gladhorn@nokia.com> | 2011-11-22 18:08:05 +0100 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-12-19 12:27:45 +0100 |
commit | 74c9f9d83f9f5cb934d0b62b468c74df5a3b9a0d (patch) | |
tree | ea5e783b8d025ce2d525dab5c524aaee298dd6b9 /util/accessibilityinspector | |
parent | 7e12d2d30f74b5fe1f80fac7192416cf6eb22d4d (diff) |
Accessibility: childAt returns interface
childAt used to return an integer.
Return an interface instead.
Not requiring a direct child to be returned allows optimizing
by bypassing iterating through the hierarchy of accessibles.
For QtQuick this is the only sensible way of implementing this.
The bridges are still responsible for finding the top-most element.
The default implementation in QAccessibleObject is sufficient
to return direct children. The implementation in
QAccessibleApplication is therfore no longer needed.
Change-Id: Id7100dd5bcc3a98de516a7f4a12eaaa41cb46d26
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Diffstat (limited to 'util/accessibilityinspector')
4 files changed, 4 insertions, 8 deletions
diff --git a/util/accessibilityinspector/accessibilityinspector.cpp b/util/accessibilityinspector/accessibilityinspector.cpp index d451ed4ac7..af7fd521e8 100644 --- a/util/accessibilityinspector/accessibilityinspector.cpp +++ b/util/accessibilityinspector/accessibilityinspector.cpp @@ -67,9 +67,6 @@ void accessibilityUpdateHandler(QObject *object, int who, QAccessible::Event rea if (updateHandlerRecursion) return; - if (!qobject_cast<QQuickItem *>(object)) - return; - updateHandlerRecursion = true; if (sceneManager) { diff --git a/util/accessibilityinspector/accessibilityinspector.h b/util/accessibilityinspector/accessibilityinspector.h index 504fecd6b5..0ec25c94e0 100644 --- a/util/accessibilityinspector/accessibilityinspector.h +++ b/util/accessibilityinspector/accessibilityinspector.h @@ -64,8 +64,6 @@ public: void saveWindowGeometry(); signals: -public slots: - private: OptionsWidget *optionsWidget; MouseInterceptingGraphicsScene *accessibilityScene; diff --git a/util/accessibilityinspector/accessibilityscenemanager.cpp b/util/accessibilityinspector/accessibilityscenemanager.cpp index 9c987271fc..9387aa625d 100644 --- a/util/accessibilityinspector/accessibilityscenemanager.cpp +++ b/util/accessibilityinspector/accessibilityscenemanager.cpp @@ -158,7 +158,7 @@ void AccessibilitySceneManager::handleUpdate(QObject *object, QAccessible::Event m_animatedObjects.clear(); } else { - qDebug() << "other update" << object; +// qDebug() << "other update" << object; } } @@ -273,7 +273,7 @@ QGraphicsRectItem * AccessibilitySceneManager::processInterface(QAccessibleInter if (!m_rootItem) m_rootItem = item; - QString name = interface->text(QAccessibleInterface::Name); + QString name = interface->text(QAccessible::Name); QString description; // = interface->text(QAccessibleInterface::Description, child); QString role = translateRole(interface->role()); int childCount = interface->childCount(); diff --git a/util/accessibilityinspector/screenreader.cpp b/util/accessibilityinspector/screenreader.cpp index 3a73f21314..aa17bfb6ee 100644 --- a/util/accessibilityinspector/screenreader.cpp +++ b/util/accessibilityinspector/screenreader.cpp @@ -103,7 +103,7 @@ void ScreenReader::processTouchPoint() qDebug() << "touchPoint exit recursion overflow"; return; // outside } - +/* hit = currentInterface->childAt(m_currentTouchPoint.x(), m_currentTouchPoint.y()); //qDebug() << "hit" << hit; if (hit == -1) { @@ -121,6 +121,7 @@ void ScreenReader::processTouchPoint() delete currentInterface; currentInterface = childInterface; } +*/ } m_selectedInterface = currentInterface; |