Biometric prompt used to set a background color
biometric_dialog_dim_color for dim effect, however
the dim background did not cover the statusbar and
navigationbar regions.
Use window manager approach for dim effect:
- Set FLAG_DIM_BEHIND for window layout params
- Set 0.5f dimAmount
- Transit dimAmount when animate away
Test: atest SystemUITests
Test: atest com.android.systemui.biometrics.AuthContainerViewTest
Test: enroll FPS, long press wifi hotsopt QS tile, then
tap "Share" affordance with the QR code icon to
bring up the biometric prompt
Bug: 237047065
Change-Id: Icbb68406357a000a61752bd03d9337acf0eb6276
43 lines
1.6 KiB
XML
43 lines
1.6 KiB
XML
<!--
|
|
~ Copyright (C) 2019 The Android Open Source Project
|
|
~
|
|
~ Licensed under the Apache License, Version 2.0 (the "License");
|
|
~ you may not use this file except in compliance with the License.
|
|
~ You may obtain a copy of the License at
|
|
~
|
|
~ http://www.apache.org/licenses/LICENSE-2.0
|
|
~
|
|
~ Unless required by applicable law or agreed to in writing, software
|
|
~ distributed under the License is distributed on an "AS IS" BASIS,
|
|
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
~ See the License for the specific language governing permissions and
|
|
~ limitations under the License.
|
|
-->
|
|
|
|
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
android:id="@+id/layout"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent">
|
|
|
|
<ImageView
|
|
android:id="@+id/background"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
android:contentDescription="@string/biometric_dialog_empty_space_description"/>
|
|
|
|
<View
|
|
android:id="@+id/panel"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
android:background="?android:attr/colorBackgroundFloating"
|
|
android:elevation="@dimen/biometric_dialog_elevation"/>
|
|
|
|
<ScrollView
|
|
android:id="@+id/biometric_scrollview"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_gravity="center_horizontal|bottom"
|
|
android:layout_margin="@dimen/biometric_dialog_border_padding"
|
|
android:elevation="@dimen/biometric_dialog_elevation"/>
|
|
|
|
</FrameLayout> |