Talkback doesn't always see platform view contents in Hybrid Composition mode #113626
Labels
a: accessibility
Accessibility, e.g. VoiceOver or TalkBack. (aka a11y)
a: platform-views
Embedding Android/iOS views in Flutter apps
engine
flutter/engine repository. See also e: labels.
P3
Issues that are less important to the Flutter project
platform-android
Android applications specifically
platform-views: hc
Issues specific to the Hybrid Composition platform views backend
team-android
Owned by Android platform team
triaged-android
Triaged by Android platform team
During investigation of #101887 I'm seeing that platform view accessibility seems to be broken in at least some cases in Hybrid Composition.
Example steps to reproduce:
webview_flutter
, making sure it's in HC mode (currently that's true by default because of the transparent background.)What I'm seeing is that the webview is completely invisible to Talkback (not only tapping, but if I enable the "dump node tree" option in Talkback developer settings, the resulting tree doesn't list the webview). It appears that this is due to the overlay view that displays the widgets that are over the platform view in the Flutter widget tree (in this case the favorites button); if I run with a local engine modified to not add the overlay view to the Flutter view, it's in the a11y node tree and can be inspected by tapping as expected (although of course other things are broken). It may be that this only happens if there are actually overlays, but I haven't investigated that yet.
The same test works fine in TLHC mode, which is not surprising since we don't use an overlay view for TLHC.
I'm not familiar enough with the internals of Android's a11y system to know why this happens; naively I would expect fully transparent view overlays to mask a11y elements that are underneath them. If possible, we need to find a way to have only the opaque parts of the overlay be treated by the a11y system as hiding what is underneath them. (/cc @chunhtai @bparrishMines )
The text was updated successfully, but these errors were encountered: