TalkBack, 10 of 10: Announce connection test feedback - #6168
eliotcougar wants to merge 7 commits into
Conversation
Keep bottom-bar accessibility semantics tied to the stable connection state while visual test progress continues to update. Emit assertive, locale-aware announcements only for test start and terminal current or bulk results, with localized spoken delay units and the native connection-test action intact.
Use millisekundu after the connection succeeded in phrase for one millisecond and other counts ending in one. The connection-test plural is already separate from standalone server-row delay units, whose nominative remains unchanged. Play Store debug resource compilation and APK assembly pass. This changes no connection-test progress or result lifetime behavior.
|
I tested this PR with TalkBack. The connection-test result itself is announced correctly when the test finishes, and there is no problem with that announcement. The issue is that the result does not remain available on the “Check status” button after the test completes. For example, if the test reports “Connected” and I hear it at that moment, everything is fine. However, if I do not hear the announcement, there is no result left on the button for TalkBack to read later. I have to run the connection test again to get the result announced again. So the problem is not that the button cannot read its status when it has one. The problem is that the test result is not retained as persistent accessible information on the button after the test finishes. Could you please check whether the latest connection-test result can remain exposed through the appropriate accessibility semantics/content of the button after the test completes, while keeping the existing one-time announcement? I did not observe any other issue with the connection-test announcement. |
|
The testing progress and result was hidden from TalkBack to prevent duplicate announcements (from the status bar and the live region at the same time). I guess, we can reset the hidden state after it was spoken once. |
Expose the localized current-test result as merged row text after its short-lived assertive live-region node retires. Keep the connection label stable and hide result text during another test, bulk progress, or disconnection. Reuse the full delay formatter and app-locale spans without changing visual text or native actions. Cover success and error results, repeated event IDs, and retained state in JVM tests. Add an Android accessibility-tree regression for live-region visibility, repeated results, and the native connection-check action.
Adopt the overlapping terminology corrections from PR 2dust#6169 and carry them into branch-only plural and accessibility resources. This keeps later merge resolution from restoring stale Bakhtiari wording.
Keep feature-specific additions away from the common translated lines changed by neighboring accessibility PRs. Preserve every resource name, value and placeholder in the existing catalog.
Reuse Part 1's live-region primitive and queue start/result publication only while the screen is resumed. Keep terminal results readable after transient feedback retires, without direct announcements or focus changes. Correlate current and bulk IPC replies by request ID, distinguish notification cancellation from completion, and acknowledge absent or cancelled native tests. Own native probe cancellation across replacement, stop, and reload so late replies cannot become fresh feedback. Replace the permanent Android fixture and copy-only helper tests with focused request/queue regressions. Validation: 64 JVM tests, Play Store debug compilation/assembly, TalkBack-preserving external emulator checks, and 20 clean pairwise merge simulations. Actual JNI stop/reload races across all service modes were not run.
Summary
Part 10 separates connection-test feedback from the continuously changing visual status:
Live-region implementation
Uses the exact same
AccessibilityLiveRegionTextimplementation as Part 1, including locale spans, stable hidden idle node, frame-separated publication, and publication acknowledgement. The identical shared file keeps both branches independently buildable and avoids an add/add conflict.Test messages are queued in publication order and held for one second after publication acknowledgement. This is a semantics lifetime, not a claim that the application can detect when TalkBack has finished speaking. Collection is limited to the resumed screen. Leaving it clears transient messages; a result received in the background remains durable ViewModel state and can be read upon return without replaying old speech.
There are no direct accessibility announcements, focus requests, native-role suppressions, or new interactive Snackbar/Toast nodes. Repeated identical tests retain distinct event IDs.
Request ownership and cancellation
Localization and scope
All nine supported catalogs contain the completion, stable connected-state, and spoken delay resources. Russian connection-delay phrasing uses the accusative singular, independently of the server-list delay resource. No XML catalogs were split, and this revision changes no translation text.
The permanent Android test fixture and copy-only status helpers were removed. Focused JVM regressions cover queue ordering, repeated results, cancellation, stale publication callbacks, and current/bulk request ownership. Temporary Android instrumentation is outside the PR.
Validation
Validated revision:
94fe07227(same tree as the merge-test candidate).Not run
The emulator's original APK and accessibility settings were preserved, with existing subscriptions and profiles left intact.