1 /* 2 * Copyright (C) 2022 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package com.android.systemui.biometrics 18 19 /** 20 * Interface for controlling the on finger down & on finger up events. 21 */ 22 interface AlternateUdfpsTouchProvider { 23 24 /** 25 * onPointerDown: 26 * 27 * This operation is used to notify the Fingerprint HAL that 28 * a fingerprint has been detected on the device's screen. 29 * 30 * See fingerprint/ISession#onPointerDown for more details. 31 */ 32 fun onPointerDown(pointerId: Long, x: Int, y: Int, minor: Float, major: Float) 33 34 /** 35 * onPointerUp: 36 * 37 * This operation can be invoked when the HAL is performing any one of: ISession#authenticate, 38 * ISession#enroll, ISession#detectInteraction. This operation is used to indicate 39 * that a fingerprint that was previously down, is now up. 40 * 41 * See fingerprint/ISession#onPointerUp for more details. 42 */ 43 fun onPointerUp(pointerId: Long) 44 45 /** 46 * onUiReady: 47 * 48 * This operation is used by the callee to notify the Fingerprint HAL that SystemUI is 49 * correctly configured for the fingerprint capture. 50 * 51 * See fingerprint/ISession#onUiReady for more details. 52 */ 53 fun onUiReady() 54 } 55