Skip to content

Support screen reader focus and activate on chat list rows#30769

Open
rezabakhshilaktasaraei wants to merge 2 commits into
telegramdesktop:devfrom
rezabakhshilaktasaraei:acc-chat-list-move-focus
Open

Support screen reader focus and activate on chat list rows#30769
rezabakhshilaktasaraei wants to merge 2 commits into
telegramdesktop:devfrom
rezabakhshilaktasaraei:acc-chat-list-move-focus

Conversation

@rezabakhshilaktasaraei

@rezabakhshilaktasaraei rezabakhshilaktasaraei commented Jun 5, 2026

Copy link
Copy Markdown
Contributor

The chat list rows are painted/virtual (no real QWidget), so a screen reader couldn't move focus to a row or activate one. With the action interface from desktop-app/lib_ui#303, those requests now reach InnerWidget:

  • Move focus → accessibilityChildSetFocus, Activate → accessibilityChildActivate. Both hop to the main thread (UIA invokes actions on a background thread) and are dispatched by stable row identity (peer / entry / result pointer), so a reordered or replaced row is never acted on by mistake.
  • An explicit accessibility SetFocus is honored directly — it is not gated on the screen-reader-mode detector, which can still be false during startup or for valid clients that aren't on its allowlist.
  • Selection and activation share selectChildByIndex(), which first clears secondary mouse hit-test state (hashtag delete, "more posts", chat-type filter, topic-jump, right button) so an Invoke can't trigger one of those instead of opening the row.
  • Default-state accessibility (count / name / state / rect / columns + selection) now goes through one mapping shared with painting and keyboard navigation — collapsed rows first, then the shown list with _skipTopDialog applied — and the collapsed Archive row is exposed.

Depends on desktop-app/lib_ui#303; CI won't compile until that is merged and the submodule updated.

@rezabakhshilaktasaraei rezabakhshilaktasaraei changed the title Move chat list selection to navigated row on screen reader focus Support screen reader focus and activate on chat list rows Jun 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant