commit | 89de57a8d252a25ef2412a11a66089a9ff6ffe29 | [log] [tgz] |
---|---|---|
author | Jeff Brown <jeffbrown@google.com> | Wed Jan 19 18:41:38 2011 -0800 |
committer | Jeff Brown <jeffbrown@google.com> | Wed Jan 19 18:41:38 2011 -0800 |
tree | 26c27db9de6f06bfd9ea0e3bb6ddae805fcccbcb | |
parent | 2cb866b948c38923b31331a9b2f031eb9d791e6e [diff] |
Fix getSwitchState. InputReader::getSwitchState always returns AKEY_STATE_UNKNOWN because SwitchInputMapper::getSources() returns 0 which cannot match any source mask including AINPUT_SOURCE_ANY. As a result initial lid switch detection is broken. This change adds a new source constant AINPUT_SOURCE_SWITCH that indicates that the source has switches. Change-Id: I5321ecf0ce84f1c2b4535f6c163d3f4dcf9b7a9b