1 /* 2 * Copyright (C) 2023 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.stylus 18 19 import com.android.internal.logging.UiEvent 20 import com.android.internal.logging.UiEventLogger 21 22 enum class StylusUiEvent(private val _id: Int) : UiEventLogger.UiEventEnum { 23 @UiEvent(doc = "UiEvent for USI low battery notification shown") 24 STYLUS_LOW_BATTERY_NOTIFICATION_SHOWN(1298), 25 @UiEvent(doc = "UiEvent for USI low battery notification clicked") 26 STYLUS_LOW_BATTERY_NOTIFICATION_CLICKED(1299), 27 @UiEvent(doc = "UiEvent for USI low battery notification dismissed") 28 STYLUS_LOW_BATTERY_NOTIFICATION_DISMISSED(1300), 29 @UiEvent(doc = "UIEvent for Toast shown when stylus started charging") 30 STYLUS_STARTED_CHARGING(1302), 31 @UiEvent(doc = "UIEvent for Toast shown when stylus stopped charging") 32 STYLUS_STOPPED_CHARGING(1303), 33 @UiEvent(doc = "UIEvent for bluetooth stylus connected") BLUETOOTH_STYLUS_CONNECTED(1304), 34 @UiEvent(doc = "UIEvent for bluetooth stylus disconnected") BLUETOOTH_STYLUS_DISCONNECTED(1305), 35 @UiEvent(doc = "UIEvent for start of a USI session via battery presence") 36 USI_STYLUS_BATTERY_PRESENCE_FIRST_DETECTED(1306), 37 @UiEvent(doc = "UIEvent for end of a USI session via battery absence") 38 USI_STYLUS_BATTERY_PRESENCE_REMOVED(1307); 39 getIdnull40 override fun getId() = _id 41 } 42