ProximityWake : Add support for checking proximity when waking device [1/2]
Framework : Fix proximity wakeup reference

Change-Id: Ia40ca6fbf6e37fbb3996f2384f725c30b88c2131
Be sure to shutdown the proximity sensor after display wake

This fixes:
http://review.cyanogenmod.org/#/c/66657/

Change-Id: I1768f13cb48c3e056d0e137642690fc3d650c4ab
ProximityWake: Fix and bring inline with CM

PS2: Clean up commit message

Change-Id: Ib35b83b2558e7516d8e80254b6e649149f270831
PowerManager : Account for values larger than maxRange for proximity

Some devices return a value larger than MaxRange, this patch accounts
for that.

(CM-Gerrit #69169 PS2)

Change-Id: I2692789afb33e777b680105513ff5d547378e78f
Proximity : Check proximity flags only if from native

Change-Id: Id1be619e638de6a45252d8390eab6e38bd5de5a7