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

Commit 681ba872 authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Merge cherrypicks of ['googleplex-android-review.googlesource.com/27874471'] into 24Q3-release.

Change-Id: I87a2d33ba37660e7efca4928c410b78a14eb6e66
parents fdf0d163 cba6d66e
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -19,8 +19,6 @@
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:sysui="http://schemas.android.com/apk/res-auto"
    android:id="@+id/alternate_bouncer"
    android:focusable="true"
    android:clickable="true"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

+1 −2
Original line number Diff line number Diff line
@@ -22,5 +22,4 @@
    android:layout_height="wrap_content"
    app:lottie_autoPlay="true"
    app:lottie_loop="true"
    app:lottie_rawRes="@raw/sfps_pulse"
    android:importantForAccessibility="no"/>
 No newline at end of file
    app:lottie_rawRes="@raw/sfps_pulse"/>
 No newline at end of file
+5 −0
Original line number Diff line number Diff line
@@ -139,6 +139,11 @@ constructor(
        overlayView!!.visibility = View.INVISIBLE
        Log.d(TAG, "show(): adding overlayView $overlayView")
        windowManager.get().addView(overlayView, overlayViewModel.defaultOverlayViewParams)
        overlayView!!.announceForAccessibility(
            applicationContext.resources.getString(
                R.string.accessibility_side_fingerprint_indicator_label
            )
        )
    }

    /** Hide the side fingerprint sensor indicator */
+4 −0
Original line number Diff line number Diff line
@@ -86,7 +86,10 @@ constructor(
                    privateFlags =
                        WindowManager.LayoutParams.PRIVATE_FLAG_TRUSTED_OVERLAY or
                            WindowManager.LayoutParams.PRIVATE_FLAG_NO_MOVE_ANIMATION
                    // Avoid announcing window title.
                    accessibilityTitle = " "
                }

    private var alternateBouncerView: ConstraintLayout? = null

    override fun start() {
@@ -304,6 +307,7 @@ constructor(
            }
        }
    }

    companion object {
        private const val TAG = "AlternateBouncerViewBinder"
        private const val swipeTag = "AlternateBouncer-SWIPE"
+8 −0
Original line number Diff line number Diff line
@@ -73,6 +73,7 @@ import org.mockito.Mockito.verify
import org.mockito.Mockito.`when`
import org.mockito.junit.MockitoJUnit
import org.mockito.junit.MockitoRule
import org.mockito.kotlin.argumentCaptor

@OptIn(ExperimentalCoroutinesApi::class)
@SmallTest
@@ -218,6 +219,13 @@ class SideFpsOverlayViewBinderTest : SysuiTestCase() {

            verify(kosmos.windowManager).addView(any(), any())

            var viewCaptor = argumentCaptor<View>()
            verify(kosmos.windowManager).addView(viewCaptor.capture(), any())
            verify(viewCaptor.firstValue)
                .announceForAccessibility(
                    mContext.getText(R.string.accessibility_side_fingerprint_indicator_label)
                )

            // Hide alternate bouncer
            kosmos.keyguardBouncerRepository.setAlternateVisible(false)
            runCurrent()