Commit Graph

9 Commits

Author SHA1 Message Date
Omkar Chandorkar ea7e5816d1
[HAX]sm8150-common: correct string name for V gesture 2021-04-03 06:57:48 +05:30
Anirudh Gupta c7100d886c sm8150-common: touch: Restore proper gesture actions
This was fixed by the kernel commit: c1244fe4ba

This commit includes a revert of commit 756dd639af.

Change-Id: I7dd248c06864eda5b0ac3269e1ebafd1ce4d43fa
2020-07-25 17:19:34 +05:30
Anirudh Gupta 756dd639af sm8150-common: touch: Switch down arrow gesture node to up arrow
The gesture node seems to be swapped on the OOS 10 source.
Switch to this since up works.

Change-Id: I0b0b994125a90222e9bdebd506e0e3672c13759a
Signed-off-by: Anirudh Gupta <anirudhgupta109@aosip.dev>
2020-05-02 14:28:27 +05:30
Anirudh Gupta 6cc1b95757 sm8150-common: DeviceSettings: Add single tap to touch screen gestures
Change-Id: I853ab1b63d682d01b7bea359111d07cf9e04d8be
Signed-off-by: Anirudh Gupta <anirudhgupta109@aosip.dev>
2020-05-02 14:27:56 +05:30
Anirudh Gupta e3a4d1112a sm8150-common: DeviceSettings: Remove refresh rate conditionally
Some devices don't have a 90Hz display and don't need the preference for this reason

To disable the feature, overlay the config to false in device specific device tree:

  overlay{,-aosip}/device/oneplus/sm8150-common/DeviceSettings/res/values/config.xml:
    <bool name="config_deviceHasHighRefreshRate">false</bool>

Suggestion by Ashwin4RC

Change-Id: I79f46adabf9d7940ca24e7077890447678a8fa8c
Signed-off-by: Anirudh Gupta <anirudhgupta109@aosip.dev>
2020-05-02 14:25:28 +05:30
Anirudh Gupta 332b826ee2 sm8150-common: DeviceSettings: Add ambient as a gesture action
Change-Id: I10661bf07b2c3c1037beed4ac5ca852b5d6f0522
Signed-off-by: Anirudh Gupta <anirudhgupta109@aosip.dev>
2020-05-02 14:18:38 +05:30
Anirudh Gupta 033bbfadc5 sm8150-common: DeviceSettings: Add Touchscreen Gesture controls
Imported from LineagePart, adapted to LineageHW implementation present in fwb instead of lineage-sdk

Change-Id: I08064ca6c7a7e58783847677843522b818c583de
TouchscreenGestureSettings class written by:
Co-authored-by: Anushek Prasal <anushekprasal@gmail.com>
Signed-off-by: Anirudh Gupta <anirudhgupta109@gmail.com>
Signed-off-by: Anirudh Gupta <anirudhgupta109@aosip.dev>
2020-05-02 14:18:27 +05:30
Anirudh Gupta 1968e51a04 sm8150-common: DeviceSettings: Show a warning about setting vibration strength too high
This commit has two benefits:
 - Helps us avoid users from complaining incase anything goes wrong with their hardware
 - Having the vibration slider as the last option meant that when trying to move the slider
   you ended up triggering the Q gesture to switch apps, this helps avoid that

Signed-off-by: Anirudh Gupta <anirudhgupta109@gmail.com>
Signed-off-by: Anirudh Gupta <anirudhgupta109@aosip.dev>
2020-05-02 14:12:10 +05:30
Anirudh Gupta aa5a4113c1 sm8150-common: Introduce DeviceSettings
Taken from: 99e6831dc4/DeviceSettings

Edits after:
 - Adapted to AndroidX
 - Includes all translations from pie cycle
 - Remove DisplayModes and Dolby
 - Add DC-Dimming, FPS Info tile, Refresh Rate preferences
 - Change layout to a cleaner look
 - Nuke KeyHandler
 - Change KeyHandler class and lib overlays to DeviceSettings
 - Make DC-Dimming and HBM QS tile reflect active status

Co-authored-by: darkobas <darkobas@gmail.com>
Co-authored-by: Max Weninger <max.weninger@gmail.com>
Co-authored-by: Vachounet <vachounet@live.fr>
Co-authored-by: kldoc <fred.berbigier@gmail.com>
Co-authored-by: Christian Oder <myself5@carbonrom.org>
Co-authored-by: Josh Fox (XlxFoXxlX) <joshfox87@gmail.com>
Co-authored-by: David Sn <divad.nnamtdeis@gmail.com>
Signed-off-by: Anirudh Gupta <anirudhgupta109@gmail.com>
Signed-off-by: Anirudh Gupta <anirudhgupta109@aosip.dev>
2020-05-02 14:12:09 +05:30