0

我使用 'androidx.biometric:biometric:1.0.1' 在使用之前在设备上显示生物识别提示,这解释了为什么用户可以在应用程序和按钮中使用指纹来拒绝

在此处输入图像描述

mBiometricManager = new BiometricManager.BiometricBuilder(context)
                    .setTitle(context.getString(R.string.screen_login_biometric_prompt_title))
                    .setSubtitle(context.getString(R.string.screen_login_biometric_prompt_subtitle))
                    .setDescription(context.getString(R.string.screen_login_biometric_prompt_description))
                    .setNegativeButtonText(context.getString(R.string.screen_login_biometric_prompt_negative_text))
                    .build();

但是在屏幕上带有扫描仪的设备上,这没有显示,只有灰色按钮可以触摸:

在此处输入图像描述 如何显示此对话框,就像在其他设备中一样:

4

0 回答 0