Use config_headlineFontFamily for password screens.
These screens are used whenever setting or confirming the lockscreen PIN or password. Set them to a consistent textSize (24sp) and a consistent fontFamily. Would have set the fontFamily in the style, but unfortunately setInputType is called on the TextViews after inflation which blows away the fontFamily. Instead, we set it in code right after that call. Change-Id: I77c3f94e2b1ce6d1f19697394c5caa09aac423b0 Fixes: 62873478 Test: manual
This commit is contained in:
@@ -30,6 +30,7 @@ import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.res.Resources.Theme;
|
||||
import android.graphics.Insets;
|
||||
import android.graphics.Typeface;
|
||||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.Message;
|
||||
@@ -375,6 +376,10 @@ public class ChooseLockPassword extends SettingsActivity {
|
||||
int currentType = mPasswordEntry.getInputType();
|
||||
mPasswordEntry.setInputType(mIsAlphaMode ? currentType
|
||||
: (InputType.TYPE_CLASS_NUMBER | InputType.TYPE_NUMBER_VARIATION_PASSWORD));
|
||||
// Can't set via XML since setInputType resets the fontFamily to null
|
||||
mPasswordEntry.setTypeface(Typeface.create(
|
||||
getContext().getString(com.android.internal.R.string.config_headlineFontFamily),
|
||||
Typeface.NORMAL));
|
||||
|
||||
Intent intent = getActivity().getIntent();
|
||||
final boolean confirmCredentials = intent.getBooleanExtra(
|
||||
|
Reference in New Issue
Block a user