Loading packages/SystemUI/res/layout/auth_credential_password_view.xml +35 −28 Original line number Diff line number Diff line Loading @@ -23,11 +23,15 @@ android:orientation="vertical" android:theme="?app:attr/lockPinPasswordStyle"> <RelativeLayout <ScrollView android:id="@+id/auth_credential_header" android:layout_width="match_parent" android:layout_height="wrap_content"> <RelativeLayout style="?headerStyle" android:layout_width="match_parent" android:layout_height="match_parent"> android:layout_height="wrap_content"> <ImageView android:id="@+id/icon" Loading @@ -39,25 +43,28 @@ <TextView android:id="@+id/title" style="?titleTextAppearance" android:layout_below="@id/icon" android:layout_width="match_parent" android:layout_height="wrap_content"/> android:layout_height="wrap_content" android:layout_below="@id/icon" /> <TextView android:id="@+id/subtitle" style="?subTitleTextAppearance" android:layout_below="@id/title" android:layout_width="match_parent" android:layout_height="wrap_content"/> android:layout_height="wrap_content" android:layout_below="@id/title" /> <TextView android:id="@+id/description" style="?descriptionTextAppearance" android:layout_below="@id/subtitle" android:layout_width="match_parent" android:layout_height="wrap_content"/> android:layout_height="wrap_content" android:layout_below="@id/subtitle" /> </RelativeLayout> </ScrollView> <LinearLayout android:id="@+id/auth_credential_input" android:layout_width="match_parent" Loading packages/SystemUI/src/com/android/systemui/biometrics/ui/CredentialPasswordView.kt +13 −4 Original line number Diff line number Diff line Loading @@ -65,7 +65,7 @@ class CredentialPasswordView(context: Context, attrs: AttributeSet?) : super.onLayout(changed, left, top, right, bottom) val inputLeftBound: Int val inputTopBound: Int var inputTopBound: Int var headerRightBound = right var headerTopBounds = top val subTitleBottom: Int = if (subtitleView.isGone) titleView.bottom else subtitleView.bottom Loading @@ -75,14 +75,23 @@ class CredentialPasswordView(context: Context, attrs: AttributeSet?) : inputLeftBound = (right - left) / 2 headerRightBound = inputLeftBound headerTopBounds -= iconView.bottom.coerceAtMost(bottomInset) if (descriptionView.bottom > bottomInset) { credentialHeader.layout(left, headerTopBounds, headerRightBound, bottom) } } else { inputTopBound = descBottom + (bottom - descBottom - credentialInput.height) / 2 inputLeftBound = (right - left - credentialInput.width) / 2 if (bottom - inputTopBound < credentialInput.height) { inputTopBound = bottom - credentialInput.height } if (descriptionView.bottom > bottomInset) { credentialHeader.layout(left, headerTopBounds, headerRightBound, bottom) if (descriptionView.bottom > inputTopBound) { credentialHeader.layout(left, headerTopBounds, headerRightBound, inputTopBound) } } credentialInput.layout(inputLeftBound, inputTopBound, right, bottom) } Loading Loading
packages/SystemUI/res/layout/auth_credential_password_view.xml +35 −28 Original line number Diff line number Diff line Loading @@ -23,11 +23,15 @@ android:orientation="vertical" android:theme="?app:attr/lockPinPasswordStyle"> <RelativeLayout <ScrollView android:id="@+id/auth_credential_header" android:layout_width="match_parent" android:layout_height="wrap_content"> <RelativeLayout style="?headerStyle" android:layout_width="match_parent" android:layout_height="match_parent"> android:layout_height="wrap_content"> <ImageView android:id="@+id/icon" Loading @@ -39,25 +43,28 @@ <TextView android:id="@+id/title" style="?titleTextAppearance" android:layout_below="@id/icon" android:layout_width="match_parent" android:layout_height="wrap_content"/> android:layout_height="wrap_content" android:layout_below="@id/icon" /> <TextView android:id="@+id/subtitle" style="?subTitleTextAppearance" android:layout_below="@id/title" android:layout_width="match_parent" android:layout_height="wrap_content"/> android:layout_height="wrap_content" android:layout_below="@id/title" /> <TextView android:id="@+id/description" style="?descriptionTextAppearance" android:layout_below="@id/subtitle" android:layout_width="match_parent" android:layout_height="wrap_content"/> android:layout_height="wrap_content" android:layout_below="@id/subtitle" /> </RelativeLayout> </ScrollView> <LinearLayout android:id="@+id/auth_credential_input" android:layout_width="match_parent" Loading
packages/SystemUI/src/com/android/systemui/biometrics/ui/CredentialPasswordView.kt +13 −4 Original line number Diff line number Diff line Loading @@ -65,7 +65,7 @@ class CredentialPasswordView(context: Context, attrs: AttributeSet?) : super.onLayout(changed, left, top, right, bottom) val inputLeftBound: Int val inputTopBound: Int var inputTopBound: Int var headerRightBound = right var headerTopBounds = top val subTitleBottom: Int = if (subtitleView.isGone) titleView.bottom else subtitleView.bottom Loading @@ -75,14 +75,23 @@ class CredentialPasswordView(context: Context, attrs: AttributeSet?) : inputLeftBound = (right - left) / 2 headerRightBound = inputLeftBound headerTopBounds -= iconView.bottom.coerceAtMost(bottomInset) if (descriptionView.bottom > bottomInset) { credentialHeader.layout(left, headerTopBounds, headerRightBound, bottom) } } else { inputTopBound = descBottom + (bottom - descBottom - credentialInput.height) / 2 inputLeftBound = (right - left - credentialInput.width) / 2 if (bottom - inputTopBound < credentialInput.height) { inputTopBound = bottom - credentialInput.height } if (descriptionView.bottom > bottomInset) { credentialHeader.layout(left, headerTopBounds, headerRightBound, bottom) if (descriptionView.bottom > inputTopBound) { credentialHeader.layout(left, headerTopBounds, headerRightBound, inputTopBound) } } credentialInput.layout(inputLeftBound, inputTopBound, right, bottom) } Loading