Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 26987e03 authored by Kweku Adams's avatar Kweku Adams
Browse files

Ensure AlarmManager knows of IDLE state.

AlarmManager relies on AlarmManager.setIdleUntil to know when the device
is entering the IDLE state. Devices that want to use a motion sensor
but don't have one normally won't proceed to the IDLE state, but someone
could force the device into the IDLE state via adb. In that situation,
AlarmManager should still be told that the device entered the IDLE
state. The alarm scheduling method expects mState to be updated before
its called, so if the method is called before the state is updated, it
will do the wrong thing.

Bug: 270672228
Test: atest DeviceIdleTest
Test: atest FrameworksMockingServicesTests:DeviceIdleControllerTest
Change-Id: I95a06e37f218bfebc86ffa6a984b50b60013af7d
parent bf1ccb78
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment