Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e5efc84a authored by Grace Cheng's avatar Grace Cheng Committed by Android (Google) Code Review
Browse files

Merge "Replace UDFPS lockscreen a11y announcements with live region" into main

parents f1b7e6fe 868f3d76
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -20,4 +20,8 @@ import android.content.Context
import android.view.View

/** Overlay to handle under-fingerprint sensor accessibility events. */
class UdfpsAccessibilityOverlay(context: Context?) : View(context)
class UdfpsAccessibilityOverlay(context: Context?) : View(context) {
    init {
        accessibilityLiveRegion = ACCESSIBILITY_LIVE_REGION_ASSERTIVE
    }
}
+4 −4
Original line number Diff line number Diff line
@@ -56,7 +56,7 @@ abstract class UdfpsAccessibilityOverlayViewModel(
                event.getPointerId(0),
                event,
                overlayParams, /* rotateToPortrait */
                false
                false,
            )

        if (
@@ -64,7 +64,7 @@ abstract class UdfpsAccessibilityOverlayViewModel(
                event.getPointerId(0),
                event,
                overlayParams,
                /* rotateTouchToPortrait */ false
                /* rotateTouchToPortrait */ false,
            )
        ) {
            // view only receives motionEvents when [visible] which requires touchExplorationEnabled
@@ -75,10 +75,10 @@ abstract class UdfpsAccessibilityOverlayViewModel(
                    scaledTouch.x,
                    scaledTouch.y,
                    overlayParams,
                    /* touchRotatedToPortrait */ false
                    /* touchRotatedToPortrait */ false,
                )
            if (announceStr != null) {
                v.announceForAccessibility(announceStr)
                v.contentDescription = announceStr
            }
        }
        // always let the motion events go through to underlying views