Loading packages/SystemUI/src/com/android/systemui/dagger/SystemUICoreStartableModule.kt +6 −1 Original line number Diff line number Diff line Loading @@ -30,7 +30,7 @@ import com.android.systemui.dreams.AssistantAttentionMonitor import com.android.systemui.dreams.DreamMonitor import com.android.systemui.dreams.homecontrols.HomeControlsDreamStartable import com.android.systemui.globalactions.GlobalActionsComponent import com.android.systemui.inputdevice.tutorial.KeyboardTouchpadTutorialCoreStartable import com.android.systemui.haptics.msdl.MSDLCoreStartable import com.android.systemui.keyboard.KeyboardUI import com.android.systemui.keyboard.PhysicalKeyboardCoreStartable import com.android.systemui.keyguard.KeyguardViewConfigurator Loading Loading @@ -323,4 +323,9 @@ abstract class SystemUICoreStartableModule { @IntoMap @ClassKey(BatteryControllerStartable::class) abstract fun bindsBatteryControllerStartable(impl: BatteryControllerStartable): CoreStartable @Binds @IntoMap @ClassKey(MSDLCoreStartable::class) abstract fun bindMSDLCoreStartable(impl: MSDLCoreStartable): CoreStartable } packages/SystemUI/src/com/android/systemui/haptics/msdl/MSDLCoreStartable.kt 0 → 100644 +34 −0 Original line number Diff line number Diff line /* * Copyright (C) 2024 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 com.android.systemui.haptics.msdl import com.android.systemui.CoreStartable import com.android.systemui.dagger.SysUISingleton import com.google.android.msdl.domain.MSDLPlayer import com.google.android.msdl.logging.MSDLHistoryLogger import java.io.PrintWriter import javax.inject.Inject @SysUISingleton class MSDLCoreStartable @Inject constructor(private val msdlPlayer: MSDLPlayer) : CoreStartable { override fun start() {} override fun dump(pw: PrintWriter, args: Array<out String>) { pw.println("MSDLPlayer history of the last ${MSDLHistoryLogger.HISTORY_SIZE} events:") msdlPlayer.getHistory().forEach { event -> pw.println("$event") } } } Loading
packages/SystemUI/src/com/android/systemui/dagger/SystemUICoreStartableModule.kt +6 −1 Original line number Diff line number Diff line Loading @@ -30,7 +30,7 @@ import com.android.systemui.dreams.AssistantAttentionMonitor import com.android.systemui.dreams.DreamMonitor import com.android.systemui.dreams.homecontrols.HomeControlsDreamStartable import com.android.systemui.globalactions.GlobalActionsComponent import com.android.systemui.inputdevice.tutorial.KeyboardTouchpadTutorialCoreStartable import com.android.systemui.haptics.msdl.MSDLCoreStartable import com.android.systemui.keyboard.KeyboardUI import com.android.systemui.keyboard.PhysicalKeyboardCoreStartable import com.android.systemui.keyguard.KeyguardViewConfigurator Loading Loading @@ -323,4 +323,9 @@ abstract class SystemUICoreStartableModule { @IntoMap @ClassKey(BatteryControllerStartable::class) abstract fun bindsBatteryControllerStartable(impl: BatteryControllerStartable): CoreStartable @Binds @IntoMap @ClassKey(MSDLCoreStartable::class) abstract fun bindMSDLCoreStartable(impl: MSDLCoreStartable): CoreStartable }
packages/SystemUI/src/com/android/systemui/haptics/msdl/MSDLCoreStartable.kt 0 → 100644 +34 −0 Original line number Diff line number Diff line /* * Copyright (C) 2024 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 com.android.systemui.haptics.msdl import com.android.systemui.CoreStartable import com.android.systemui.dagger.SysUISingleton import com.google.android.msdl.domain.MSDLPlayer import com.google.android.msdl.logging.MSDLHistoryLogger import java.io.PrintWriter import javax.inject.Inject @SysUISingleton class MSDLCoreStartable @Inject constructor(private val msdlPlayer: MSDLPlayer) : CoreStartable { override fun start() {} override fun dump(pw: PrintWriter, args: Array<out String>) { pw.println("MSDLPlayer history of the last ${MSDLHistoryLogger.HISTORY_SIZE} events:") msdlPlayer.getHistory().forEach { event -> pw.println("$event") } } }