summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/cocoa/qnsviewaccessibility.mm
Commit message (Collapse)AuthorAgeFilesLines
* Mac Accessibility: unify child functionsFrederik Gladhorn2013-06-241-18/+1
| | | | | | | | | Both ways of getting the children are the same for nsview and qcocoaaccessibleelement. Factor out a function. Change-Id: I4be091c6acde0de519a358f879c24eae04ec4c8d Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Mac Accessibility: skip invisible childrenFrederik Gladhorn2013-06-211-0/+3
| | | | | Change-Id: I6c3da526ecef60447a658b6b5501282729e9c6f5 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Cocoa Accessibility: fix ignoring of objectsFrederik Gladhorn2013-06-071-1/+1
| | | | | | | | | | | | | | | | | On Mac it's expected that some elements are filtered out of the a11y hierarchy. We do this with the shouldBeIgnored function. The problem is that we would ignore some objects and then return them in the child attribute function. This is inconsistent and leads to voice over not working. For example having a plain QWidget with other widgets as children would cut off all of these widgets, since the plain QWidget would be ignored. Change-Id: I5f6c26b272e5ca57d59c1ed1ef47e9a2b1181295 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com> Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Accessibility Mac: Implement accessibilityFocusedUIElementFrederik Gladhorn2013-04-221-0/+18
| | | | | | Change-Id: I17b5b1f741a8b340d8f4b16f4ec39cc9a8159bfa Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com> Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Let platform plugin decide if accessibility is activeFrederik Gladhorn2013-04-191-7/+12
| | | | | Change-Id: I881a8ff3fedf3db73ee37046a4363c70960a92a6 Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Cache QAccessibleInterfaces.Frederik Gladhorn2013-04-021-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | Since there already is a one-to-one relationship between QObject and QAccessibleInterface it makes little sense to create and destroy the interfaces on each call to queryAccessibleInterface. Add a cache and keep created interfaces around for the lifetime of the corresponding QObject. This changes the memory management rules: accessible interfaces must no longer be deleted. If you get an QAccessibleIntrface pointer that pointer will stay valid as long as the corresponding QObject is not deleted. This also re-enables accessibility for Mac. We limit the range of the IDs so that they are useable for Windows directly. That means we can get rid of the event cache there. This is based on: Iebf2f374916fc70a9dd29e95f45a6444b85f6cee Change-Id: I9fe6531812c0dbc5b41101ac05830a6dd75e13a3 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* Make qaccessible2.h internal.Frederik Gladhorn2013-03-141-1/+1
| | | | | | | | | | | This should have been done right from the start, instead we only made the documentation internal. Also remove the classes from the BIC data. Change-Id: I238a7a7cc5d26980b23931c78e7e5a4477d46920 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-181-1/+1
| | | | | Change-Id: Ic804938fc352291d011800d21e549c10acac66fb Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* More explicit QCocoaAccessibleElement memory mngmtMorten Johan Sorvig2013-01-091-2/+5
| | | | | | | | | | Don't autorelease in the elementWithInterface function, rename it to createElementWithInterface. The element can then be released immediately or autoreleased ("delete later"). Change-Id: I155a85404c34d756c1752eb7c24a7fb0f3cf2e77 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Don't use NSAccessibilityUnignoredChildren.Morten Johan Sorvig2012-12-141-1/+1
| | | | | | | | | | The function is massively ineffective on deep hierarchies and not strictly needed. (It's supposed to filter out "Ignored" children - VoiceOver will do that anyway based on accessibilityIsIgnored()) Change-Id: I9a74b5f5e9b7880e0d46d5330f7192472eac7a36 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Cocoa: Disable accessibility.Morten Johan Sørvig2012-12-011-0/+4
| | | | | | | | | The accessibility implementation is unstable and causes application crashes. Disable until it has been stabilized. Change-Id: Ic34361a0ad599c6f92df722499d274fe0655646b Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Accessibility Mac: Return textArea as role for multi line text.Frederik Gladhorn2012-11-231-1/+1
| | | | | | Change-Id: I88eb4746463b7372c2dfe089ba74ea4cb0098396 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com> Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-221-24/+24
| | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: If1cc974286d29fd01ec6c19dd4719a67f4c3f00e Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Cocoa: silence warnings about unused variablesBradley T. Hughes2012-03-261-1/+0
| | | | | | | | Silence warnings about unused function parameters and local variables while building the Cocoa platform plugin. Change-Id: I6aedc4cb21c5fb48d2d6e501561473d3f7112aed Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I311e001373776812699d6efc045b5f742890c689 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Use QObject pointer as QCocoaAccessibleElement id.Morten Johan Sorvig2012-01-231-3/+3
| | | | | | | | | | | | | | | Each QCocoaAccessibleElement needs to provide a unique stable id through the -(NSUnterger)hash method. The previous approach of basing the hash on the parent hash plus the child index is unpractical now that childAt() can return distant descendants instead of immediate children only. Use the QObject pointer, which is set for all accessible interfaces today. Change-Id: I5868e3a81c1b4da7233504f30003ab8060e9fa3f Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Update contact information in license headers.Jason McDonald2012-01-231-1/+1
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Ignore uninteresting accessibile interfaces.Morten Johan Sorvig2012-01-121-1/+3
| | | | | | | | | Certain interface roles should be ignored and not be a part of the user-visible accessibility interface tree. Change-Id: I264fef909052c528ee505875e3a211a33114d881 Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Add support for accessibility actions.Morten Johan Sorvig2012-01-111-1/+1
| | | | | | | | Match Cocoa and Qt actions manually. Some have no corresponding action on the other side. Change-Id: I775cb8987ab843bd88d57d856ef7c0403290db00 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
* Update copyright year in license headers.Jason McDonald2012-01-051-1/+1
| | | | | Change-Id: I02f2c620296fcd91d4967d58767ea33fc4e1e7dc Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Accessibility: childAt returns interfaceFrederik Gladhorn2011-12-191-23/+8
| | | | | | | | | | | | | | | | | | 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>
* Cocoa: Add initial accessibility implementation.Morten Sorvig2011-10-191-0/+117
See qcocoaaccessiblity.h for details. For now only the first level of the hierarchy is made accessible. Also add tools/accessibilityinspector which is an utility for inspecting and debugging the Qt accessibility tree. Change-Id: Iff520bec26b3761feb0c2e00471feb379daaa735 Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>