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 package com.android.systemui.statusbar.phone
17 
18 import android.content.Context
19 import android.graphics.Rect
20 import android.view.View
21 import com.android.systemui.statusbar.StatusBarIconView
22 import com.android.systemui.statusbar.notification.collection.ListEntry
23 
24 /**
25  * A controller for the space in the status bar to the left of the system icons. This area is
26  * normally reserved for notifications.
27  */
28 interface NotificationIconAreaController {
29     /** Called by the Keyguard*ViewController whose view contains the aod icons. */
setupAodIconsnull30     fun setupAodIcons(aodIcons: NotificationIconContainer?)
31     fun setShelfIcons(icons: NotificationIconContainer)
32     fun onDensityOrFontScaleChanged(context: Context)
33 
34     /** Returns the view that represents the notification area. */
35     fun getNotificationInnerAreaView(): View?
36 
37     /** Updates the notifications with the given list of notifications to display. */
38     fun updateNotificationIcons(entries: List<@JvmSuppressWildcards ListEntry>)
39     fun updateAodNotificationIcons()
40     fun showIconIsolated(icon: StatusBarIconView?, animated: Boolean)
41     fun setIsolatedIconLocation(iconDrawingRect: Rect, requireStateUpdate: Boolean)
42     fun setAnimationsEnabled(enabled: Boolean)
43     fun onThemeChanged()
44     fun getHeight(): Int
45 }
46