Improve heuristics for detecting wireless chargers.

On some devices, we need to apply heuristics to determine whether
the device is docked on a wireless charger because the charging
circuits do not provide sufficient information to know whether
the device is on the charger unless it is actually receiving

The previous heuristics only considered the battery level to
suppress spurious dock signals.

The new heuristics also take into account whether the device
appears to have moved from its previous position on the dock.

Bug: 7744185
Change-Id: I5ba885dac25b37840b6db46b8a0f30968a06776c
3 files changed