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

Don't disable GPS in Doze until the device is stationary.

GPS is normally disabled when the device is Dozing. This means that GPS
is turned off in Battery Saver when quick doze is enabled. This
interferes with navigation and possibly other use cases. This changes
the behavior so that GPS is only disabled during Dozing if the device is
stationary. This will not interfere with regular Doze since the device
has to be stationary before it will enter regular Doze, and also allows
GPS to continue to work when Quick Doze activates while the user is
still carrying the device around.

Bug: 140162457
Test: atest BatterySaverLocationTest
Test: atest com.android.server.DeviceIdleControllerTest
Test: [manual] Shorten motion timeout, step into idle, check gps
provider dump after short timeout to check mDisableGpsForPowerManager=true
Merged-In: I7bc68c8a5e6744aac3a160ac14fc3375f9374d82
Change-Id: I7bc68c8a5e6744aac3a160ac14fc3375f9374d82
(cherry picked from commit 810c77d5)
parent 06a28b06
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