Add notifications for the concurrent display mode
Show system notifications when the concurrent display mode is active or when the concurrent display mode is canceled due to critical thermal condition. Summary of the changes: 1. Added DeviceStateNotificationController to manage the device state notifications. 2. In DeviceStateProvider, added "reason" to the callback onSupportedDeviceStatesChanged to indicate the cause of the supported device states change (e.g. change due to thermal condition) 3. In OverrideRequestController, added flags to the onStatusChanged callback to indicate the cause of status change (e.g. FLAG_THERMAL_CRITICAL means that the change is caused by critical thermal condition). 4. In OverrideRequest, added a uid field, which is used to get the app name displayed in the notification. Fix: 266096470, 261127342, 264799106 Test: atest com.android.server.policy.DeviceStateProviderImplTest com.android.server.devicestate.DeviceStateManagerServiceTest com.android.server.devicestate.OverrideRequestControllerTest com.android.server.devicestate.DeviceStateNotificationControllerTest Change-Id: Ieb590d47dfbfd37e9e732b179a63ed25e080d0f0
Loading
Please register or sign in to comment