Fix UDFPS enrolling crash
Bug: b/271208595 Test: 1. adb root 2. adb shell setprop sys.fflag.override.settings_biometrics2_enrollment true 3. Record fingerprint 4. Check setting work normally Change-Id: I69cc50cd677e80a57bb430a5a295c46b519d7755
This commit is contained in:
@@ -226,6 +226,10 @@ public class UdfpsEnrollView extends FrameLayout {
|
||||
}
|
||||
|
||||
DisplayInfo displayInfo = new DisplayInfo();
|
||||
if (getDisplay() == null) {
|
||||
android.util.Log.e(TAG, "Can not get display");
|
||||
return;
|
||||
}
|
||||
getDisplay().getDisplayInfo(displayInfo);
|
||||
Rect udfpsBounds = mSensorProperties.getLocation().getRect();
|
||||
float scaleFactor = mUdfpsUtils.getScaleFactor(displayInfo);
|
||||
|
Reference in New Issue
Block a user