'Android talkback reads background text behind the bottomsheet

When bottom sheet is shown in my app want to stop talkback reading background text. The behaviour works fine in Google News app.

Issue:

  • Talkback setting is ON.
  • Launch the app fragment is shown.
  • Bottomsheet is shown on top of fragment covering half of the screen.
  • Talkback reads background text first then reads bottomsheet text.

Fix I want is stop reading background text.



Solution 1:[1]

Have you tried setting android:importantForAccessibility="no" on this background view?

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 mabulazm