Skip to content

NVDAObjects.UIA: do not interrupt say all when handling high priority UIA notification#18218

Merged
SaschaCowley merged 6 commits into
nvaccess:masterfrom
josephsl:i17986sayAllWithUIANotificationEvent
Jun 13, 2025
Merged

NVDAObjects.UIA: do not interrupt say all when handling high priority UIA notification#18218
SaschaCowley merged 6 commits into
nvaccess:masterfrom
josephsl:i17986sayAllWithUIANotificationEvent

Conversation

@josephsl

@josephsl josephsl commented Jun 5, 2025

Copy link
Copy Markdown
Contributor

Link to issue number:

Closes #17986

Summary of the issue:

While say all is in progress, NVDA interrupts speech while handling a high priority UIA notification. This was observed in Microsoft Edge where say all is active while notifications such as "loading complete" is announced.

Description of user facing changes:

In Microsoft Edge, NVDA will no longer interrupt say all when announcing notifications such as "loading complete".

Description of developer facing changes:

Changes to NVDAObjects.UIA's notification event handler:

  • Speech priority flag is prepared as it will become either None or NOW (speak immediately) depending on the condition below.
  • Set speech prioirty to NOW if say lal is in progress, otherwise cancel speech.
  • UIA notification display string will be reported immediately during say all (and thus not interrupting say all).

Description of development approach:

First tested as part of Windows App Essentials add-on/global plugin portion, then ported to NVDA Core and tested manually (below).

Testing strategy:

Manual testing:

  1. Run Microsoft Edge.
  2. Visit a website known to take a long time to load.
  3. NVDA should start say aol if "automatic say all on page load" is enabled, otherwise do a manual say all (NVDA+down arrow (desktop)/NVDA+A (laptop)).
  4. Observe that:

Before: NVDA interrupts speech when notifications such as "loading page/still loading/loading complete" are announced.
With the PR: NVDA will continue performing say all after announcing UIA notification display string.

Known issues with pull request:

When a page is refreshed and say all is initiated and notifications are reported, NVDA may play error tones (due to null pointer being passed into code injection routine). This does not impact say all.

Code Review Checklist:

  • Documentation:
    • Change log entry
    • User Documentation
    • Developer / Technical Documentation
    • Context sensitive help for GUI changes
  • Testing:
    • Unit tests
    • System (end to end) tests
    • Manual testing
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers
    • Localization in other languages / culture than English
  • API is compatible with existing add-ons.
  • Security precautions taken.

@coderabbitai summary

josephsl added 3 commits June 4, 2025 18:26
…cation is received. Re nvaccess#17986.

Observed in Microsoft Edge: when say all is active (activated manually or with say all on page load enabled), NVDA will interrupt a say all in progress if a high priority notification such as 'loading complete' is received. Therefore, only cancel speech if say all is inactive, otherwise change speech priority parameter of ui.message to 'NOW' (speak immediately) - handle the UIA notification and then continue with say all.
…vaccess#17986.

This change can be both a bug fix and a change. However, as this is not a bug caused by NVDA per say, therefore add it under changes section.
@josephsl josephsl requested a review from a team as a code owner June 5, 2025 00:46
@josephsl josephsl requested a review from SaschaCowley June 5, 2025 00:46
@seanbudd seanbudd added the conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review. label Jun 10, 2025
Comment thread user_docs/en/changes.md Outdated

@SaschaCowley SaschaCowley left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @josephsl

@SaschaCowley SaschaCowley merged commit 92c79c3 into nvaccess:master Jun 13, 2025
4 of 5 checks passed
@github-actions github-actions Bot added this to the 2025.2 milestone Jun 13, 2025
@josephsl josephsl deleted the i17986sayAllWithUIANotificationEvent branch June 15, 2025 12:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"Loading Complete" message interrupts the screen reader & the rest of the page is not read.

3 participants