From 0f75ed396fdd1c7a65d024955befaa77c7c4302c Mon Sep 17 00:00:00 2001 From: Ilya Matyukhin Date: Thu, 18 Mar 2021 12:10:45 +0000 Subject: Introduce IUdfpsHbmListener Bug: 181682258 Test: atest CommandQueueTest Change-Id: Ia03b845ff036d7267a5dfb5691da33562fda2aab --- .../hardware/fingerprint/IUdfpsHbmListener.aidl | 47 ++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 core/java/android/hardware/fingerprint/IUdfpsHbmListener.aidl (limited to 'core/java/android') diff --git a/core/java/android/hardware/fingerprint/IUdfpsHbmListener.aidl b/core/java/android/hardware/fingerprint/IUdfpsHbmListener.aidl new file mode 100644 index 000000000000..b79d6e0f9dfe --- /dev/null +++ b/core/java/android/hardware/fingerprint/IUdfpsHbmListener.aidl @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2021 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package android.hardware.fingerprint; + +/** + * A listener for the high-brightness mode (HBM) transitions. This allows other components to + * perform certain actions when the HBM is toggled on or off. For example, a display manager + * implementation can subscribe to these events from UdfpsController and adjust the display's + * refresh rate when the HBM is enabled. + * + * @hide + */ +oneway interface IUdfpsHbmListener { + /** + * UdfpsController will call this method when the HBM is enabled. + * + * @param hbmType The type of HBM that was enabled. See + * {@link com.android.systemui.biometrics.HbmTypes}. + * @param displayId The displayId for which the HBM is enabled. See + * {@link android.view.Display#getDisplayId()}. + */ + void onHbmEnabled(int hbmType, int displayId); + + /** + * UdfpsController will call this method when the HBM is disabled. + * + * @param hbmType The type of HBM that was disabled. See + * {@link com.android.systemui.biometrics.HbmTypes}. + * @param displayId The displayId for which the HBM is disabled. See + * {@link android.view.Display#getDisplayId()}. + */ + void onHbmDisabled(int hbmType, int displayId); +} + -- cgit v1.2.3