diff --git a/packages/SystemUI/res/values/lmodroid_config.xml b/packages/SystemUI/res/values/lmodroid_config.xml index 7e78003fb5831a761e1484e90f045d7fd08ddbdf..ddff98fe60ed93024bd34117044d3bfeef0115ad 100644 --- a/packages/SystemUI/res/values/lmodroid_config.xml +++ b/packages/SystemUI/res/values/lmodroid_config.xml @@ -21,6 +21,12 @@ <!-- Color of the UDFPS pressed view --> <color name="config_udfpsColor">#ffffffff</color> + <!-- HBM type of UDFPS overlay. + 0 - GLOBAL HBM + 1 - LOCAL HBM + --> + <integer name="config_udfpsHbmType">1</integer> + <!-- Udfps HBM provider class name --> <string name="config_udfpsHbmProviderComponent">com.android.systemui.biometrics.DummyUdfpsHbmProvider</string> </resources> diff --git a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsView.java b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsView.java index 30e5aed2f8d8c47b739a805afb929931845ecd70..e4cbb527d338603c3056b1f2f4b564327383b720 100644 --- a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsView.java +++ b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsView.java @@ -51,7 +51,6 @@ public class UdfpsView extends FrameLayout implements DozeReceiver, UdfpsIllumin private static final String SETTING_HBM_TYPE = "com.android.systemui.biometrics.UdfpsSurfaceView.hbmType"; - private static final @HbmType int DEFAULT_HBM_TYPE = UdfpsHbmTypes.LOCAL_HBM; private static final int DEBUG_TEXT_SIZE_PX = 32; @@ -99,9 +98,11 @@ public class UdfpsView extends FrameLayout implements DozeReceiver, UdfpsIllumin if (Build.IS_ENG || Build.IS_USERDEBUG) { mHbmType = Settings.Secure.getIntForUser(mContext.getContentResolver(), - SETTING_HBM_TYPE, DEFAULT_HBM_TYPE, UserHandle.USER_CURRENT); + SETTING_HBM_TYPE, + mContext.getResources().getInteger(R.integer.config_udfpsHbmType), + UserHandle.USER_CURRENT); } else { - mHbmType = DEFAULT_HBM_TYPE; + mHbmType = mContext.getResources().getInteger(R.integer.config_udfpsHbmType); } }