Commits
Dianne Hackborn authored 80fa166bf6d
Fix issue #2171766: Device can go to sleep while in dock The issue I saw was then when plugging into the dock, we the battery first is in the "USB" state before going to "AC". The phone window manager would pick up the first state, but not the second. This change reworks this code to always monitor the battery status while plugged in to the dock, to update itself whenever that state changes. When not in the dock, we don't monitor, since this is only used to determine whether to keep the device on while in the dock. Change-Id: Ic1e8b584082a44c4e5df13ee19dab450775027f6