summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/windows/uiautomation
Commit message (Collapse)AuthorAgeFilesLines
* windows: Fix typos in source code commentsJonas Kvinge2021-10-121-2/+2
| | | | | Change-Id: I5d83574639d0b1f935843a75217aae70a5925fa0 Reviewed-by: André de la Rocha <andre.rocha@qt.io>
* Windows QPA: Fix coordinates reported through UI AutomationAndré de la Rocha2021-07-271-10/+7
| | | | | | | | | | | | | | Conversion to/from native screen coordinates was incorrect and could fail for non-primary screens. This could cause a control's bounding rectangle to be incorrectly reported, or a search for a control based on its position within the window to fail, causing incorrect behavior with accessibility tools and other software interacting with the application using UI Automation. Fixes: QTBUG-91459 Pick-to: 6.2 6.1 5.15 Change-Id: I5d56584ff26d977cdd34d35af46644e32aa11e7c Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Windows QPA: Fix accessibility focus event for table/tree/listAndre de la Rocha2021-03-251-0/+11
| | | | | | | | | | | | The focused element within a table, tree or list was not being informed in the UI Automation focus change events, causing the focused element to be missed by screen readers. Fixes: QTBUG-91029 Pick-to: 6.0 6.1 5.15 Change-Id: I738502e6871358508b4510763018837c304b618e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Return the result we have already when getting an object with no nameAndy Shaw2021-03-241-1/+1
| | | | | | | | | | This will ensure that something is set for the AutomationId based on the actual object and the parents that do have object names until it reaches one without an object name. Pick-to: 6.1 6.0 5.15 Change-Id: I205485bc0ba772e321879e00e64ea8e1d8f1ba91 Reviewed-by: André de la Rocha <andre.rocha@qt.io>
* Windows QPA: Fix crashes when using screen reader with Q(Plain)TextEditFriedemann Kleint2021-01-121-2/+6
| | | | | | | | | Make sure the search start with valid values. Pick-to: 6.0 5.15 Task-number: QTBUG-89354 Change-Id: I5b5100db89c62f23748b5c88e9188cfe3811e6e8 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Remove the qmake project filesJoerg Bornemann2021-01-071-43/+0
| | | | | | | | | | | | | | | | Remove the qmake project files for most of Qt. Leave the qmake project files for examples, because we still test those in the CI to ensure qmake does not regress. Also leave the qmake project files for utils and other minor parts that lack CMake project files. Task-number: QTBUG-88742 Change-Id: I6cdf059e6204816f617f9624f3ea9822703f73cc Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Deprecate QVariant::TypeLars Knoll2020-10-231-1/+1
| | | | | | | | | It's been obsolete for a long time already. Make sure the compiler now warns about it and remove all remaining uses in qtbase. Change-Id: I0ff80311184dba52d2ba5f4e2fabe0d47fdc59d7 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Use QList instead of QVector in pluginsJarek Kobus2020-07-061-2/+1
| | | | | | Task-number: QTBUG-84469 Change-Id: Ic86f4a3000592a1c9ae62e4a83f4fe39832a6b24 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Move windowsuiautomation API support into QtGuiFriedemann Kleint2020-05-274-6/+3
| | | | | | Task-number: QTBUG-83255 Change-Id: Ibface71931b6384494842ba9744d76f738c5ca85 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Sweep of int-ish → char-ish types near calls to QString::fromU*()Marc Mutz2020-05-121-1/+1
| | | | | | | | | | | | The fromUtf16(ushort*) and fromUcs4(uint*) overloads are going to be deprecated. Use the newer fromUtf16(char16_t*) and fromUcs4(char32_t*) overloads. As a drive-by, use std::end()/std::size() where applicable. Change-Id: I5a93e38cae4a2e33d49c90d06c5f14f7cb7ce90c Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Windows QPA: Fix missing accessible name change eventsAndre de la Rocha2020-05-103-0/+17
| | | | | | | | | | | | | | Accessible name change events were not being relayed through UI Automation. This caused changes in the state of combo boxes and possibly other quick controls to be missed by UI Automation clients. This would result, for instance, in Narrator not reading the state of a combo box when its current index was changed with the keyboard. Fixes: QTBUG-70621 Pick-to: 5.15 Change-Id: I16de0ff2bb0fb5227111d5347c25f442e9b0a533 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Windows QPA: Enable Toggle UIA pattern for all checkable controlsAndre de la Rocha2020-03-261-4/+2
| | | | | | | | | This change allows the checked/unchecked state to be detected by screen readers for all controls with a checkable state. Task-number: QTBUG-81919 Change-Id: I604151397b4ae21297009c274ffe634723ebe783 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Merge remote-tracking branch 'origin/5.14' into 5.15Mitch Curtis2020-03-201-0/+1
|\ | | | | | | Change-Id: Ib2a2e3a292af43be3a980c2ccc943c08f4bbf72f
| * Windows QPA: Do not play sound for QMessageBox::NoIconFriedemann Kleint2020-03-061-0/+1
| | | | | | | | | | | | | | | | | | | | Amends 2f366a63b20a943ae3099605c2cdb34009ca5602. Task-number: QTBUG-82682 Task-number: QTBUG-81342 Change-Id: I30f465bf432e27828db460f6dbbb59eee0cca8f2 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: André de la Rocha <andre.rocha@qt.io>
* | Windows QPA: Add support to UiaRaiseNotificationEvent()Andre de la Rocha2020-03-041-5/+21
| | | | | | | | | | | | | | | | | | | | | | This change adds support to UiaRaiseNotificationEvent() in the UI Automation-based accessibility code, and uses it to notify changes in string-typed values, allowing Narrator, NVDA and other screen readers to notice changes in the application state that were previously missed. Fixes: QTBUG-75003 Change-Id: I646ca3a851ab7b69817d900b002eb91a3bf607a6 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Rename AA_MSWindowsDisableVirtualKeyboard to AA_DisableNativeVirtualKeyboardAndre de la Rocha2020-02-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | Renaming the attribute to make it platform-independent, since in spite of currently being supported only on Windows, it may be eventually supported on other platforms where it may be useful. Task-number: QTBUG-76088 Change-Id: Id98ccd7a34e1c43b1f2274efce6ab4b4aff24f03 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Liang Qi2020-02-184-0/+200
|\| | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qlinkedlist.h src/plugins/platforms/wasm/qwasmintegration.cpp src/plugins/platforms/wasm/qwasmscreen.cpp Change-Id: Iefca7f9f4966bdc20e7052aca736874861055738
| * Windows QPA: Implement IExpandCollapseProvider for submenusAndre de la Rocha2020-02-124-0/+200
| | | | | | | | | | | | | | | | | | | | | | Menu items with submenus should implement the Expand/Collapse UI Automation pattern in order to allow screen readers to say whether they are expandable items. Fixes: QTBUG-80550 Change-Id: I4f72d30172f76f028be5cbdeb1fd85fca6b07acf Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | Windows QPA: Add support to IsDialog UIA propertyAndre de la Rocha2020-02-132-1/+5
| | | | | | | | | | | | | | | | | | | | Adding support to the IsDialog property within the UI Automation code. This property allows dialog windows to be identified as such, which may be used by screen readers to better describe them. Fixes: QTBUG-82019 Change-Id: I6f5478dd30f63f152cba75886a9e0eb38772037a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2020-01-151-0/+53
|\| | | | | | | Change-Id: I8dbcf23835d52d3aa7d018ed250814d60c68aa83
| * Windows QPA: Fix message box and other system soundsFriedemann Kleint2020-01-141-0/+53
| | | | | | | | | | | | | | | | | | | | | | Re-add the code hooking into QWindowsUiaAccessibility::notifyAccessibilityUpdate() which was removed by 0cf6297c15be45d852be98c862bd0211e6de1aa2. Fixes: QTBUG-81342 Change-Id: Ie97d7cca5b774196d53b675c92d84f4ce208f987 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | Windows QPA: Allow the native Windows virtual keyboard to be disabledAndre de la Rocha2019-12-171-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | This change provides a way to disable the automatic showing of the native Windows on-screen virtual keyboard when a text editing widget is selected on a system without a physical keyboard, by enabling the new AA_MSWindowsDisableVirtualKeyboard application attribute, allowing applications to use a custom virtual keyboard implementation. Fixes: QTBUG-76088 Change-Id: Id76f9673a2e4081e5325662f3e3b4b102d133b9a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | Windows QPA: Use UTF-16 literals where possibleFriedemann Kleint2019-12-161-1/+1
| | | | | | | | | | | | | | This should minimize diffs to Qt 6. Change-Id: Id74c0b4085085984bd51251765420718d16e9fc7 Reviewed-by: André de la Rocha <andre.rocha@qt.io>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Liang Qi2019-12-101-1/+2
|\| | | | | | | | | | | | | Conflicts: tests/auto/network/kernel/qnetworkinterface/BLACKLIST Change-Id: I1e8866c63b54bcd95fc2a044276ee15b7f60e79a
| * Windows QPA: Export "checkable" info for menu items through UI AutomationAndre de la Rocha2019-12-101-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | In order to allow screen readers to say checked/unchecked for checkable menu items, this information has to be provided through UI Automation. Checkable menu items should implement the "Toggle" UI Automation pattern. The "checkable" state must also be supported by QAccessibleMenuItem, which is being added by a separated change. Task-number: QTBUG-80551 Change-Id: I661668310d1b6b4701d0c0efdb1dcfd15d0db729 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Ulf Hermann2019-12-031-1/+11
|\| | | | | | | | | | | | | Conflicts: src/corelib/serialization/qcborvalue.cpp Change-Id: I675a3029955c96e81a33ed9d98b72b55b6784b52
| * Windows QPA: Disable the native Windows OSK if Qt Virtual Keyboard is in useAndre de la Rocha2019-11-251-1/+11
| | | | | | | | | | | | | | | | | | | | This change detects that the Qt Virtual Keyboard is in use through the QT_IM_MODULE environment variable and disables the native Windows OSK accordingly, to avoid showing both virtual keyboards at the same time. Task-number: QTBUG-76088 Change-Id: I2715b337e6de729f0514ea1892b94b3c4f9cd984 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Windows QPA: Port from QList to QVectorFriedemann Kleint2019-11-202-3/+4
|/ | | | | | | | Use a QVector where possible. Otherwise, try to introduce auto to make migration easier. Change-Id: I9deadb363fabd1755deca180ed5cb771390fcb30 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-11-131-2/+3
|\ | | | | | | | | | | | | | | Conflicts: examples/widgets/widgets/scribble/mainwindow.cpp This amends cb54c16584cf3be746a1a536c1e37cb3022a2f1b. Change-Id: Iaae60a893330524b2973917e23b31f9d51f8bd38
| * Windows QPA: Avoid returning UI Automation ValueProvider for static textAndre de la Rocha2019-11-071-2/+3
| | | | | | | | | | | | | | | | | | | | | | Static text controls should not return a ValueProvider. Otherwise, Narrator reads out static texts and announces whether they are editable or not, which is confusing to users. It should only read out the text itself. Fixes: QTBUG-79613 Change-Id: I080cd6a5db10f6f673b50c40ac7d87c3737d9b55 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | QWindowsUiaTextRangeProvider: replace ephemeral QList<QRect> with QVLAMarc Mutz2019-09-081-1/+2
| | | | | | | | | | | | | | | | | | QList<QRect> is horribly inefficient™. Since the container only lives for the duration of the function call, use QVLA instead. Change-Id: I2d179caef37bb78efface5547ff8bfcdc8f9a6ac Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-09-041-11/+19
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/codecs/qicucodec.cpp src/dbus/qdbusserver.cpp src/gui/painting/qbezier.cpp src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.cpp src/plugins/printsupport/cups/qppdprintdevice.cpp Change-Id: I2703128bb64baf5580fbc2c2061b55b0f0611d2a
| * Windows QPA: Fix crash in UI Automation with Youdao DictionaryAndre de la Rocha2019-09-021-11/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Unlike other accessibility classes, QAccessibleTree is returning a different instance, with a different ID, every time child()/childAt() are called for the same child elements. This causes ElementProviderFromPoint to return different IRawElementProviderSimple instances every time, for the same coordinates, which causes the NetEase Youdao Dictionary to call it in an infinite loop, allocating new QAccessibleTableCell instances, until the application crashes. The crash happened, for instance, just by using the mouse over Qt Creator's project tree while Youdao Dictionary was running. While the root cause seems to be QAccessibleTree not caching and reusing objects, this change adds a layer of safety to the UI Automation classes in the Windows QPA, to avoid causing a crash until QAccessibleTree, and possibly other accessibility classes, are fixed. Fixes: QTBUG-77974 Change-Id: I9b0c8174bc0fd9ef7f5626ee0b72c8a9626520ee Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | Do not access invalid QAccessibleInterfaceJan Arve Sæther2019-07-051-1/+1
| | | | | | | | | | | | | | Noticed this when running Qt Creator against dev Change-Id: Ie75b2e0f2a77033ce0455d7ee3304193aa6e511c Reviewed-by: André de la Rocha <andre.rocha@qt.io>
* | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-06-141-1/+1
|\| | | | | | | | | | | | | | | | | | | Conflicts: qmake/generators/makefile.cpp qmake/generators/unix/unixmake2.cpp src/corelib/thread/qthread_unix.cpp tests/auto/corelib/tools/qsharedpointer/tst_qsharedpointer.cpp Change-Id: I1df0d4ba20685de7f9300bf07458c13376493408
| * Windows QPA: Fix clang warnings about narrowing conversionsFriedemann Kleint2019-05-291-1/+1
| | | | | | | | | | | | Change-Id: Iba173b45fb77918694fc2c7506885fdeef9f6064 Reviewed-by: André de la Rocha <andre.rocha@qt.io>
* | Windows QPA: Fix clang warnings about repetitive type namesFriedemann Kleint2019-06-133-7/+7
| | | | | | | | | | | | | | | | | | | | Fix warning like: warning: use auto when initializing with new/reinterpret_cast to avoid duplicating the type name [modernize-use-auto] Change-Id: Ieb7f052919173f6923e68de9f9e849dee45e36e7 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | Windows QPA: Replace Q_DISABLE_COPY by Q_DISABLE_COPY_MOVEFriedemann Kleint2019-05-2414-14/+14
| | | | | | | | | | | | | | | | | | | | | | Fix clang warnings like: warning: class 'QWindowsStaticOpenGLContext' defines a default destructor, a copy constructor and a copy assignment operator but does not define a move constructor or a move assignment operator [cppcoreguidelines-special-member-functions Change-Id: I736d20476ef407100b6ecb654d1112106e545758 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | Merge remote-tracking branch 'origin/5.13' into devFriedemann Kleint2019-05-274-6/+264
|\| | | | | | | Change-Id: Ia279fc4a8226626041c772902a07b2f90f37b53b
| * Windows Accessibility: window should be focusableFrederik Gladhorn2019-05-211-6/+15
| | | | | | | | | | | | Fixes: QTBUG-75001 Change-Id: Iac67b9bba70317f8d28ac2d355d584417d1ffebf Reviewed-by: André de la Rocha <andre.rocha@qt.io>
| * Windows Accessibility: Add UI Automation Window providerFrederik Gladhorn2019-05-204-0/+249
| | | | | | | | | | | | | | | | | | This allows closing, minimizing and maximizing the window. Fixes: QTBUG-74999 Change-Id: I8b3ad806a1767586c8cf7e5a1848fc0e525621cd Reviewed-by: André de la Rocha <andre.rocha@qt.io>
* | Migrate Windows system libs to external dependenciesJoerg Bornemann2019-05-081-2/+1
|/ | | | | | Started-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Change-Id: I211ce3252b836894aeeac1c85eb316d9596bca57 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Windows QPA: Fix QComboBox accessibility with screen readersAndre de la Rocha2019-04-123-2/+39
| | | | | | | | | | | | Screen readers like NVDA and Narrator were not reading the contents of a QComboBox when changing its value using the keyboard, without expanding it, due to missing UI Automation notifications in this case. This change should also help in other cases where updated string values were not notified to screen readers. Fixes: QTBUG-75066 Change-Id: Id7f488380aec5ad27fd11b3cf854d44ab1b28688 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Windows/Direct2d QPA: Use nullptrFriedemann Kleint2019-01-281-1/+1
| | | | | Change-Id: I6ce01caa58de78e0eb61e243ee1e7b05cc1f5568 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Windows UI automation: Add missing overrideFriedemann Kleint2018-09-261-1/+1
| | | | | | | | | | Fix warning by clang-cl: qwindowsuiamainprovider.h(89,31): warning: 'SetFocus' overrides a member function but is not marked 'override' [-Winconsistent-missing-override] HRESULT STDMETHODCALLTYPE SetFocus(); Task-number: QTBUG-63512 Change-Id: Iac3cbf8577423ed799796034953be39ed1663116 Reviewed-by: Miguel Costa <miguel.costa@qt.io>
* Merge remote-tracking branch 'origin/5.11' into 5.12Qt Forward Merge Bot2018-09-071-4/+18
|\ | | | | | | Change-Id: I66c7f18a2abd13601da0947919436f7da3549ae9
| * Windows QPA: Fix missing accessibility info with WebEngineViewAndre de la Rocha2018-09-041-4/+18
| | | | | | | | | | | | | | | | | | | | | | | | It seems when a WebEngineView is parented by a window its accessible interface will not know its parent, which prevented the root of an UI Automation fragment from being found, causing missing accessibility info. This change adds a workaround to avoid this issue. Task-number: QTBUG-70199 Change-Id: Ia7cfc9f410c4f0ef3b5f9d1700748a9a3e29b7c2 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* | Merge remote-tracking branch 'origin/5.11' into 5.12Liang Qi2018-08-221-1/+1
|\| | | | | | | | | | | | | | | | | Conflicts: src/gui/text/qtextengine.cpp tests/auto/corelib/itemmodels/qsortfilterproxymodel_common/tst_qsortfilterproxymodel.cpp tests/auto/corelib/itemmodels/qsortfilterproxymodel_common/tst_qsortfilterproxymodel.h Change-Id: Ib9f968edbb0f3387c89bc25e914321d0738bfadc
| * Windows QPA: Fix mapping of static text accessibility roleAndre de la Rocha2018-08-171-1/+1
| | | | | | | | | | | | | | | | | | QAccessible::StaticText should be mapped to UIA_TextControlTypeId instead of UIA_EditControlTypeId. Task-number: QTBUG-69894 Change-Id: If2f8f55d2be492c02a3af5b1813ca12cf774a33a Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | Merge remote-tracking branch 'origin/5.11' into devQt Forward Merge Bot2018-08-072-16/+13
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/corelib/doc/src/objectmodel/signalsandslots.qdoc src/plugins/platforms/cocoa/qcocoamenuloader.mm src/plugins/platforms/xcb/qxcbconnection.cpp src/plugins/platforms/xcb/qxcbconnection.h src/plugins/platforms/xcb/qxcbconnection_xi2.cpp src/plugins/platforms/xcb/qxcbwindow.cpp tests/auto/gui/image/qimage/tst_qimage.cpp Done-with: Gatis Paeglis <gatis.paeglis@qt.io> Change-Id: I9bd24ee9b00d4f26c8f344ce3970aa6e93935ff5