Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b29814c4 authored by Jim Miller's avatar Jim Miller
Browse files

Don't show fingerprint cancellation messages in keyguard

Cancellation messages can come from a variety of sources
and are not user-actionable.  As a result, we just shouldn't
show them.

Fixes bug 22863862

Change-Id: I2154c774fd5ac7477e01d1cbf3bdde2d1929363b
parent d14c4844
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -29,6 +29,7 @@ import android.content.pm.ActivityInfo;
import android.content.pm.PackageManager;
import android.content.pm.ResolveInfo;
import android.content.res.Configuration;
import android.hardware.fingerprint.FingerprintManager;
import android.os.AsyncTask;
import android.os.Bundle;
import android.os.IBinder;
@@ -601,6 +602,7 @@ public class KeyguardBottomAreaView extends FrameLayout implements View.OnClickL
    }

    private final BroadcastReceiver mDevicePolicyReceiver = new BroadcastReceiver() {
        @Override
        public void onReceive(Context context, Intent intent) {
            post(new Runnable() {
                @Override
@@ -671,7 +673,8 @@ public class KeyguardBottomAreaView extends FrameLayout implements View.OnClickL

        @Override
        public void onFingerprintError(int msgId, String errString) {
            if (!KeyguardUpdateMonitor.getInstance(mContext).isUnlockingWithFingerprintAllowed()) {
            if (!KeyguardUpdateMonitor.getInstance(mContext).isUnlockingWithFingerprintAllowed()
                    || msgId == FingerprintManager.FINGERPRINT_ERROR_CANCELED) {
                return;
            }
            // TODO: Go to bouncer if this is "too many attempts" (lockout) error.