Fix the illumination dot getting stuck

Bug: 158135499
Test: manual on device
Change-Id: Ie0e063e67940a178218272078049e202e233bb01
This commit is contained in:
Ilya Matyukhin
2020-07-13 15:42:51 -07:00
parent 767eb0faad
commit 8e9a3cf84d
2 changed files with 3 additions and 2 deletions

View File

@@ -156,6 +156,7 @@ class UdfpsController {
}
private void hideUdfpsOverlay() {
onFingerUp();
mHandler.post(() -> {
Log.v(TAG, "hideUdfpsOverlay | removing window");
if (mIsOverlayShowing) {

View File

@@ -143,12 +143,12 @@ public class UdfpsView extends View {
void onFingerDown() {
mIsFingerDown = true;
mSensorPaint.setStyle(Paint.Style.FILL);
invalidate();
postInvalidate();
}
void onFingerUp() {
mIsFingerDown = false;
mSensorPaint.setStyle(Paint.Style.STROKE);
invalidate();
postInvalidate();
}
}