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

Unverified Commit 17de2815 authored by Michael Bestas's avatar Michael Bestas
Browse files

Revert "udfps: Make pressed udfp view configurable"

Will need to be reimplemented for qpr1

This reverts commit 70ae3cda.

Change-Id: Ibdfb36baee3ef9b258e66945acee498bad8e8795
parent 46eca017
Loading
Loading
Loading
Loading
−108 B
Loading image diff...
+0 −3
Original line number Diff line number Diff line
@@ -25,9 +25,6 @@
         causes a poor experience. -->
    <bool name="config_fingerprintWakeAndUnlock">true</bool>

    <!-- Color of the UDFPS pressed view -->
    <color name="config_udfpsColor">#ffffffff</color>

    <!-- Udfps HBM provider class name -->
    <string name="config_udfpsHbmProviderComponent">com.android.systemui.biometrics.DummyUdfpsHbmProvider</string>

+1 −15
Original line number Diff line number Diff line
@@ -19,7 +19,6 @@ package com.android.systemui.biometrics;
import android.annotation.NonNull;
import android.annotation.Nullable;
import android.content.Context;
import android.graphics.drawable.Drawable;
import android.graphics.Canvas;
import android.graphics.Paint;
import android.graphics.PixelFormat;
@@ -30,8 +29,6 @@ import android.view.Surface;
import android.view.SurfaceHolder;
import android.view.SurfaceView;

import com.android.systemui.R;

/**
 * Surface View for providing the Global High-Brightness Mode (GHBM) illumination for UDFPS.
 */
@@ -57,8 +54,6 @@ public class UdfpsSurfaceView extends SurfaceView implements SurfaceHolder.Callb
    boolean mAwaitingSurfaceToStartIllumination;
    boolean mHasValidSurface;

    private Drawable mUdfpsIconPressed;

    public UdfpsSurfaceView(Context context, AttributeSet attrs) {
        super(context, attrs);

@@ -74,10 +69,8 @@ public class UdfpsSurfaceView extends SurfaceView implements SurfaceHolder.Callb

        mSensorPaint = new Paint(0 /* flags */);
        mSensorPaint.setAntiAlias(true);
        mSensorPaint.setColor(context.getColor(R.color.config_udfpsColor));
        mSensorPaint.setARGB(255, 255, 255, 255);
        mSensorPaint.setStyle(Paint.Style.FILL);

        mUdfpsIconPressed = context.getDrawable(R.drawable.udfps_icon_pressed);
    }

    @Override public void surfaceCreated(SurfaceHolder holder) {
@@ -141,13 +134,6 @@ public class UdfpsSurfaceView extends SurfaceView implements SurfaceHolder.Callb
        Canvas canvas = null;
        try {
            canvas = mHolder.lockCanvas();
            mUdfpsIconPressed.setBounds(
                    Math.round(sensorRect.left),
                    Math.round(sensorRect.top),
                    Math.round(sensorRect.right),
                    Math.round(sensorRect.bottom)
            );
            mUdfpsIconPressed.draw(canvas);
            canvas.drawOval(sensorRect, mSensorPaint);
        } finally {
            // Make sure the surface is never left in a bad state.