diff options
author | Michael Weghorn <[email protected]> | 2024-08-29 11:27:02 +0200 |
---|---|---|
committer | Volker Hilsheimer <[email protected]> | 2024-09-09 18:17:58 +0000 |
commit | 13b4075093866a497e620bdd388afaf8aa0bc962 (patch) | |
tree | ee6dd0d7ac7db03c4d46c113e639e51ce32b4b5f | |
parent | ebbe7221df9edec7abe9bd3286fabb76e2741652 (diff) |
a11y: Use desktop file name as app's accessible ID
As the QGuiApplication::desktopFileName doc [1] says:
> This is the file name, without the full path or the
> trailing ".desktop" extension of the desktop entry that
> represents this application according to the freedesktop
> desktop entry specification.
Since the desktop entry represents the application, also
use the desktop file name for the accessible ID of the
application object.
This e.g. makes Okular's application object report an
accessible ID of "org.kde.okular" instead of just "QApplication"
as the AT-SPI2 AccessibleId property on Linux.
[1] https://doc.qt.io/qt-6/qguiapplication.html#desktopFileName-prop
Pick-to: 6.8
Change-Id: I554da7baaf817866db9044128f73a9ea634cddbf
Reviewed-by: Volker Hilsheimer <[email protected]>
-rw-r--r-- | src/gui/accessible/qaccessibleobject.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gui/accessible/qaccessibleobject.cpp b/src/gui/accessible/qaccessibleobject.cpp index 61d3a90632f..017c9f82cae 100644 --- a/src/gui/accessible/qaccessibleobject.cpp +++ b/src/gui/accessible/qaccessibleobject.cpp @@ -182,6 +182,8 @@ QString QAccessibleApplication::text(QAccessible::Text t) const return QGuiApplication::applicationName(); case QAccessible::Description: return QGuiApplication::applicationFilePath(); + case QAccessible::Identifier: + return QGuiApplication::desktopFileName(); default: break; } |