Rotation related corrections

- There are some conditions deleted while placing rotation angles code, I added them.

- Rotation lock was screwed up since CM 12. Fixed it by fetching allowed rotations from CM's
allowed rotations setting.

- Also, a CAF commit had killed rotation lock ability.

[port to 15.1]:
 - ACCELEROMETER_ROTATION_ANGLES moved to LineageSDK
 - Slight change of the WindowManager API

[port to 16.0]:
 - adjust context
 - ACCELEROMETER_ROTATION_ANGLES moved to Settings
 - Use the configstore API

Change-Id: I8f1b468249c68e7b6514d1a96bdb3fc638af84fd
Signed-off-by: eray orçunus <erayorcunus@gmail.com>
(cherry picked from commit a62720d51e9d8f3a3c9992ea0bdb707b64e865b5)
3 files changed