Bug 1817611 - Revert using live region for talkback on navbar swipe

A previous PR introduced accessibilityLiveRegion for EngineView
in order for talkback to dictate when swiping to another tab on navbar.
This change lead to talkback dictating the title/url of the current
page even when tapping empty spaces or when certain elements lose focus.
Changing the implementation from using live regions to the
announceForAccessibility method seems to fix this issue.
fenix/112.0
DreVla 1 year ago committed by mergify[bot]
parent 59eae2858b
commit 177013bdfc

@ -1136,8 +1136,6 @@ abstract class BaseBrowserFragment :
updateThemeForSession(selectedTab)
}
binding.engineView.asView().contentDescription = selectedTab.toDisplayTitle()
if (browserInitialized) {
view?.let {
fullScreenChanged(false)
@ -1146,6 +1144,7 @@ abstract class BaseBrowserFragment :
val toolbarHeight = resources.getDimensionPixelSize(R.dimen.browser_toolbar_height)
val context = requireContext()
resumeDownloadDialogState(selectedTab.id, context.components.core.store, context, toolbarHeight)
it.announceForAccessibility(selectedTab.toDisplayTitle())
}
} else {
view?.let { view -> initializeUI(view) }

@ -32,7 +32,6 @@
android:id="@+id/engineView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:accessibilityLiveRegion="polite"
android:visibility="gone" />
</mozilla.components.ui.widgets.VerticalSwipeRefreshLayout>

Loading…
Cancel
Save