Commit graph

143672 commits

Author SHA1 Message Date
Michael Bestas
24abb4f5ac
Settings: Add toggle for heads up notifications
Change-Id: Ie2f50e3fac70268d1cf0c0cab6cd23d9aec7cdc7
2024-10-25 03:09:43 +03:00
Bruno Martins
8b03dbdbee
KeyboardSettings: Add a RemotePreference for device-specific panel
Allow devices to provide advanced keyboard settings.

Unfortunatelly this can't be done with existing IA settings,
so use the RemotePreference API to allow the external app
to update the view. The action for this is:

     "org.lineageos.settings.device.ADVANCED_KEYBOARD_SETTINGS"

Change-Id: I1c46d3568c4d5bfc78e1cbae033071c7641fdf29
2024-10-25 03:09:43 +03:00
Sam Mortimer
2b4208ba48
Settings: Add battery and notification lights settings
Change-Id: Ia5f635d2a493a859068af3d6b7502cc6d3db5893
2024-10-25 03:09:38 +03:00
Cosmin Tanislav
339aa781a7
Settings: gestures: Add page for Screen-Off UDFPS
Change-Id: I313969384fe605d7b5ff7dfc3a3fcebd514dd7cf
2024-10-25 03:09:38 +03:00
Chirayu Desai
be0be1f547
Hide the "Show the vibrate icon in the Status Bar" setting
* We have this controllable like all other status bar icons

Change-Id: I39d2f0ee7849403c404bdfa109e191102466c537
2024-10-25 03:09:37 +03:00
Cédric Bellegarde
61719239fa
Settings: Add preference for one shot auto-brightness
Co-authored-by: Eamon Powell <eamonpowell@outlook.com>
Change-Id: I57f11ad4e8fc47b2ff2c771e61920780e359815f
2024-10-25 03:09:27 +03:00
LuK1337
7a1d2bb263
Settings: Hide settings that don't work when taskbar is enabled
Change-Id: I81f0f8ad645bec95579bd0487f3f1098ab5823df
2024-10-25 03:09:27 +03:00
LuK1337
3af1cb3d67
Settings: Add min refresh rate list preference
Change-Id: Iac1f65ab09717ea55a5b471e094385c77ba894ee
2024-10-25 03:09:27 +03:00
Michael Bestas
f9a4057104
Settings: Add peak refresh rate list preference
* AOSP "Smooth display" setting is just a toggle,
  some devices support multiple refresh rates so
  add support for it with a ListPreference.

Change-Id: I3da3d2b86e61ed3caf9af5770d8bdb4485817b97
2024-10-25 03:08:56 +03:00
Ramii Ahmed
eeac2b8f4c
Settings: Display: Add High Touch Polling Rate Support
Change-Id: I86e85c5cd2cf462734ccad69b41b1977b32c7326
2024-10-25 03:08:18 +03:00
Terminator-J
7b6251325b
Settings: Show single-touch wakeup setting on rear & front fps devices
Not sure why Google assumed that showing this setting is only useful
for devices with FP sensor built into a side-mounted power button.

Change logic to preserve check for side mounted (really, power-button
mounted) FP sensors, but allow any device which has a a rear or front
mounted sensor to show the relevant setting; so users can toggle it.

Bug: Enchilada (Oneplus 6, capacitive FP sensor on the back) no longer
wakes & unlocks from screen-off with FP sensor touch after QPR3 merge.

Test: Apply commit. "Touch to unlock anytime" setting is now visible;
enabling once again allows one-touch wakeup-and-unlock-on-successful-
FP-auth, does nothing with failed FP auth, while disabling toggle
requires pressing power button to wake screen first before FP auth
will unlock.

Change-Id: I4d8204b5fed7d43baa93d6793e7280260ae404d6
2024-10-25 03:08:18 +03:00
Michael Bestas
c56b21910b
Hide SFPS wakeup setting when it's not supported
Change-Id: I22d4eb745379a6ca56b8fe23e1584131c4e945a6
2024-10-25 03:08:17 +03:00
Michael Bestas
881c801e64
Hide fingerprint settings help if URL is empty
Change-Id: I1631575bd6e48419f0649491a5ae167adf72c8c2
2024-10-25 03:08:17 +03:00
Bruno Martins
72e64a7fd4
fingerprint: Rework enrollment screen
This is based on the following changes, adapted to Android 12
considering the fact that AOSP now supports FOD as well as
fingerprint sensors embedded in the power button:

Author: d34d <clark@cyngn.com>
Date:   2016-06-23 11:21:45 -0700

    fingerprint: Allow devices to configure sensor location

    The text for enrolling a fingerprint always assumes the sensor is
    located on the back.  This patch adds a config integer that defines
    where the sensor is located on the device.
      0 = back
      1 = front
      2 = left side
      3 = right side

    This patch also adds a new drawable that shows the front of the device
    when applicable.

    Change-Id: Ia8f5f8ff4ba4d13d35aed3052f60ff665dd4f294
    TICKET: CYNGNOS-3089

Author: Paul Keith <javelinanddart@gmail.com>
Date:   2018-01-26 22:23:03 +0100

    FingerprintEnrollFindSensor: Don't overlay front for side sensors

    * Both the base image and the base image + overlay are equally nonsense
      for devices with a side fingerprint scanner, but for those that overlay
      a custom fingerprint enrollment graphic, this image overlay wreaks havoc
    * Only set this overlay to be visible if the sensor is on the front, to
      allow devices with side sensors to only overlay the base image

    Change-Id: I7cbcea4830d4526cf9f7d139e7f84f21117fa9c4

Author: Michael W <baddaemon87@gmail.com>
Date:   Thu Jan 17 21:44:28 2019 +0100

    Settings: Make find fingerprint look great again

    * The current logic places the animation based on the size of
      the whole overlay instead of the image, which is a fixed-size png
    * Get the size of the image instead and place the dot relative to it
    * Also use "wrap_content" and add a padding to the top so the
      distance to the text is a fixed thing, not depending on how
      much space relative to the wanted space it actually takes

    * Preview: https://imgur.com/a/XanJ2aP

    Change-Id: I2bd08cee1abd1c6bad78ca1efc2189e573ded3cc

Author: LuK1337 <priv.luk@gmail.com>
Date:   Sat Dec 15 17:11:41 2018 +0100

    fingerprint: Remove unnecessary spacing in enroll layout

    * This makes it look ugly on 480 dpi devices.

    Change-Id: Ia1bbd443063a125878dddd12e5c6a816d289fb82

Author: Bruno Martins <bgcngm@gmail.com>
Date:   Thu Mar 17 10:30:41 2022 +0000

    FingerprintEnrollEnrolling: Set proper dialog message when user touches fp icon

    Change-Id: Iafd86e636b0c54bbddcf26d153cc671259391259

Author: Michael Bestas <mkbestas@lineageos.org>
Date:   Tue Dec 6 20:40:45 2022 +0200

    Use AOSP string for side fps enrollment

    Change-Id: I9267b6a75716f45044f4d7a51650ca4f928b104e

Author: Bruno Martins <bgcngm@gmail.com>
Date:   Tue Apr 18 16:16:34 2023 +0100

    FingerprintEnroll: Add config for dedicated side mounted fps

    Google likes to assume that there only exists devices with
    fingerprint sensor embedded in the power button, but that's
    not always true. Since specific enrollment messages were added
    just for those devices, we need to address our own usecase.

    Change-Id: I56a7d7fe0374fe5a1fce5e24bdbb265cb5edc246

Change-Id: If372ef50c4a719e89a4e80cc20e3eb445af61bc6
2024-10-25 03:08:17 +03:00
Timi Rautamäki
5680f3f9dd
fingerprint: hide link icon when there's no link
Test: verify fingerprint setup doesn't have link icon without a link.
Change-Id: I040500615815ffe9256089a9bc11b07da783fa79
2024-10-25 03:08:17 +03:00
Bruno Martins
8220125571
Settings: Add FastCharge preference into Battery settings
* Several OEMs let the user decide whether to enable or disable quick
   charging technology when using a quickcharge charger.
   Samsung, for example, exposes a sysfs node to disable it at
   will, depending on what the user sets in battery settings UI.

 * Disabling fast charge may be useful for reducing the heat produced by
   the device while charging, or for extending the lifespan of the battery.

 * This commit introduces a switch preference for disabling fastcharge
   on devices that support said feature.

Change-Id: I7dd09d357e9bd555a8efeaf9ee191e52b9f2d151
2024-10-25 03:08:17 +03:00
Jesse Chan
5a9f8188dc
Settings: Add an option to force pre-O apps to use full screen aspect ratio
When an app target pre-O releases, the default max aspect ratio
is 1.86:1 which leads to ugly black areas on devices that have
screens with higher aspect ratio (for example Galaxy S8/S9).

This change adds an option to allow users to change aspect ratio
for pre-O apps to full screen aspect ratio.

Change-Id: I0fb73511cf654ee22a4cfb7aef252008f8db8855
2024-10-25 03:08:17 +03:00
Danny Baumann
d238eb0ab4
Settings: Add setup UI for minimum delay between an app's notification sounds
Co-authored-by: LuK1337 <priv.luk@gmail.com>
Change-Id: I70e9cc308b4f7c7681457a0b09dd73e5d1aebb73
2024-10-25 03:08:04 +03:00
Jon Evans
180969ff17
Settings: display: Add wake on plug switch
Change-Id: I22ee2a05040561cca796814573adc5226f1f03d4
2024-10-25 03:08:04 +03:00
Bruno Martins
d19b7cc1fe
Settings: Add proximity check on wake preference
Splitted from commit 5aa2f34, adapted to the Lineage SDK
and squashed with commits c6dc688 and 19105ab.

Change-Id: I7516c833ff39de6bdb36c815a5292606cbaa0533
2024-10-25 03:08:04 +03:00
LuK1337
9dfd2d8626
Settings: Add high touch sensitivity and touchscreen hovering toggles
Co-authored-by: Bruno Martins <bgcngm@gmail.com>
Change-Id: Ib8712d2d0c0fe4396dbea7c7fc130e0c253d3207
2024-10-25 03:07:44 +03:00
Tommy Webb
ac0a813011
POLICY_REJECT_ALL restricts all network access
Read and write POLICY_REJECT_ALL instead of manipulating the setting
designated for the restricted mode allowlist.

Requires: I74407c21cd4ed2cdd932d634577ae07d0bad67b1
Change-Id: I354fae215dcb15e1bf3a67ff4c94803eb60fcac1
2024-10-25 03:07:43 +03:00
Bruno Martins
6b68075767
Settings: Move SIM restrictions currently applied to per-app data usage
When Google introduced commit d3b35f2, all the custom addons for
per-app network isolation became hidden on devices that set the
overlay config_show_sim_info to "false".

Expose only the toggles that really make sense, i.e. for the mentioned
usecase, leave the main toggle (restrict all), WiFi and VPN data
toggles.

Change-Id: I4720483d98ae69fbb6eec8fa749e8d071e91c629
2024-10-25 03:07:43 +03:00
Oliver Scott
679f7051c8
AppDataUsage: Handle apps without INTERNET permission
* Disable network restriction toggles for apps without INTERNET permission

Change-Id: I1481b6f27912bf6559920e32b0072868d4f83a4c
2024-10-25 03:07:43 +03:00
Oliver Scott
9e77479883
Settings: Add support for allowing/disallowing apps on cellular, vpn and wifi networks
*) Add options to disable all cellular, vpn and wifi data
   in app data usage settings.

*) Disable the existing background data and unrestricted
   data usage options when all cellular data access is
   disabled.

*) The vpn data option can be selected independently from
   the Wi-Fi and cellular options.

*) Prevent DataSaverBackend from overwriting uid policies

This is a replacement for the appops menu based cell/wifi data
restriction settings in cm-13.0:
Author: Danesh M <daneshm90@gmail.com>
Date:   Mon Mar 7 15:17:59 2016 -0800
    Settings : Add per app internet/data control
    CYAN-3976
    CRACKLING-834
    Change-Id: I13192df837c057b5cadde8f31532e12daaf3c1b0

Change-Id: Ic087c27a5ed0bdb84bb8f297c425c6bcbffec848
(cherry picked from commit d4a2eea698cbc4636a635d60f2a52ec1bbc36ba2)
2024-10-25 03:07:43 +03:00
Sam Mortimer
5f9367f7dd
Settings: Add support for allowing/disallowing apps on restricted networks
*) Add option to disable all network traffic
   in app data usage settings.

*) Disable the existing background data and unrestricted
   data usage options when all network traffic is
   disabled.

Change-Id: I0aaf5703d6dd5d6e6ec3cda3940f28833fe052ea
2024-10-25 03:07:43 +03:00
Adnan
551d0a5fb3
Settings: Add option to scramble pin layout when unlocking (1/2).
Change-Id: I3e2c200a0a31d3c765831bc30280029a50c88051
2024-10-25 03:07:43 +03:00
Sam Mortimer
70e41c7a25
Settings: Add hotspot setting to allow VPN upstreams
Change-Id: I34924fe8e60e3d492f219aa6d0ffa54f0bd46e38
2024-10-25 03:07:43 +03:00
Rashed Abdel-Tawab
f0d36b8f95
Settings: Only show gesture navigation if device has a software nav bar
Change-Id: Ic90c8a194a736807c2e101ffd5f7e90c86a55381
2024-10-25 03:07:43 +03:00
Bruno Martins
066aca6f52
Settings: Allow devices to provide remote gesture preferences
* Not all devices can use common gestures as implemented in LineageParts

Change-Id: Iae4ca9fc686e3dc82411524688841211e0cceb7b
2024-10-25 03:07:43 +03:00
Zhao Wei Liew
897be6f76a
Settings: gesture: Add LineageParts touchscreen gesture settings
We'll allow devices to add touchscreen gesture settings
using the LineageHW TouchscreenGesture API.

Change-Id: I569b91ed66d34097a2bd96fb56af660a2702224b
2024-10-25 03:07:43 +03:00
Michael Bestas
645bf12d4f
Remove useless USB page header
* This causes the options to go off screen and almost always
  require scrolling in order to reach all the options.

Change-Id: I3880982978aa50f11bf24b4da6e91a0917181811
2024-10-25 03:07:43 +03:00
Rashed Abdel-Tawab
06884e6f9d
Settings: Add double tap to sleep preference
* Place it under Display settings, near the existing
   double tap to wake preference.

Change-Id: I0baa49f9367331febf29260a0f60ba3a020be729
2024-10-25 03:07:43 +03:00
inthewaves
282aaa9c2b
get outer NFC preference to listen for changes
The NFC preference in Settings -> Connected devices -> Connection
preferences doesn't listen to changes from the NFC tile. (This wasn't an
issue in Android 10, because there used to be a SwitchPreference that
listened there.)

Change-Id: I85842db3faa558ea61bc878ca76ff6d8ce1a4b02
2024-10-25 03:07:43 +03:00
Danny Lin
a11294901b
Fix inconsistent USB preference screen title
The title of the USB preference screen ("USB Preferences") is
inconsistent in several ways:

1. It doesn't match the title of the preference that launches it
2. No other preference screens say "preferences" in their title, since
   it's redundant
3. It violates the Material text conventions, which prefer to not
   capitalize titles in the UI

This commit changes it to "USB", which fixes all of the inconsistencies
listed above.

Change-Id: I7330a9e4e121d57ee2140ef60aefb4412b1fe728
2024-10-25 03:07:43 +03:00
Paul Keith
438a0825fe
Settings: Add livedisplay preference screen
We can't inject via IA if we want to disable the preference via
config_enableLiveDisplay

Change-Id: I482a073e9c699d3f2bc5870567d603ceca2065b1
2024-10-25 03:07:02 +03:00
Alexander Koskovich
6ee00c8ce9
Handle mobile data on internet page during setup
Change-Id: Id00e9ef135cd2748376c69596979826e764e9185
2024-10-25 03:07:02 +03:00
Michael Bestas
b3c3cdfbf4
Settings: Network setup UI changes for SUW
Co-authored-by: Dhina17 <dhinalogu@gmail.com>
Co-authored-by: Erfan Abdi <erfangplus@gmail.com>
Co-authored-by: Michael Bestas <mkbestas@lineageos.org>
Change-Id: Ic8e97b78f19e59fe108c7c3304dfe7e7f49020a9
2024-10-25 03:07:02 +03:00
Timi Rautamäki
3ce2befcb8
Settings: use Glif themed button bar
Change-Id: I7b7c522730806ee9c8cc83e4f560a344a089cbec
2024-10-25 03:06:55 +03:00
Jesse Chan
9e0c432632
Settings: Implement hide gestural navigation hint bar
Co-authored-by: Bruno Martins <bgcngm@gmail.com>
Change-Id: I1089683a0ad4561bc303006ae61897ff44fff0e9
2024-10-25 03:06:40 +03:00
Steve Kondik
7d434c91e3
Settings: Add a RemotePreference for device-specific doze settings
* If a device has its own panel, we should replace the item under
   display settings instead of having to clutter up the dashboard.
 * Devices that provide Doze settings typically implement own AOD pref,
   so hide AOSP one.
 * This uses the new RemotePreference API to allow the external
   app to update the view.
 * The action for this is "org.lineageos.settings.device.DOZE_SETTINGS".

Co-authored-by: Bruno Martins <bgcngm@gmail.com>
Change-Id: I22fd7e6307b370807415ce2132bed4808b2befe1
2024-10-25 03:06:00 +03:00
Wang Han
27b6142e9e
Settings: Hide unsupported USB modes automatically
* The roles are advertised by USB HAL so we can check for their status

Change-Id: I5933d1a03f573af08b00039850173329b293448a
2024-10-25 03:06:00 +03:00
Luca Stefani
7a82d1308e
Settings: Check if we have any color modes declared in overlay
* Checking for wide gamut support isn't always enough

Change-Id: Ic7257e37f2eca97450eaf0ca1e330de7596352be
2024-10-25 03:06:00 +03:00
Michael Bestas
c141746f35
Settings: Forward port pattern visibility settings (2/2)
Change-Id: Ic627953c5df854c442671a98b5da539b994da18b
2024-10-25 03:06:00 +03:00
Michael Bestas
1aa106b02b
Settings: Forward port lock pattern grid size (2/2)
Co-authored-by: Alberto97 <albertop2197@gmail.com>
Co-authored-by: d34d <clark@cyngn.com>
Co-authored-by: Dhina17 <dhinalogu@gmail.com>
Co-authored-by: LuK1337 <priv.luk@gmail.com>
Co-authored-by: Roman Birg <roman@cyngn.com>
Change-Id: I7078d703c218cd096d9b77c003a94b52fbce6322
2024-10-25 03:06:00 +03:00
Michael Bestas
d9c793e9c6
Settings: Fix the failing strings
Having double quotes around the strings causes crowdin
to export translations with unescaped quotes.
Removing them has no side effect and fixes crowdin export.

Change-Id: I93865d793eef711f8738e00e843e9d4670724c66
2024-10-25 03:04:44 +03:00
Sam Mortimer
25e59205b9
Settings: Add LineageParts charging sound settings preference
Replace the existing AOSP setting with this.

Change-Id: I13894a86bcfad8d1dfaedc2dcbca6ad70f651b5c
2024-10-25 03:04:44 +03:00
Michael Bestas
a29dca94cd
Don't reset A2DP offload when disabling developer settings
* We need to disable A2DP HW offload on FP4 for now, however
  disabling developer settings would enable offload again and
  break SBC and AAC audio. Just remove this section and allow
  this setting to persist after disabling developer settings.

Change-Id: I5b65b3887d68ac684d7ea78de0ee89fb7db9bb0f
2024-10-25 03:04:43 +03:00
Chirayu Desai
73e3b3163f
One does not simply become a Developer
Co-authored-by: Michael Bestas <mikeioannina@gmail.com>
Change-Id: I64ab4d7ab9d8334275d2e4d493b716a8fc73ab4e
2024-10-25 03:04:17 +03:00
Roman Birg
4dc0fb0386
Settings: Add LineageOS legal info
Open up the LineageOS legal info in the browser.

Change-Id: I263ccc0509e275d17512528deb606341d58e7a0d
Ticket-Id: CYNGNOS-1895
Signed-off-by: Roman Birg <roman@cyngn.com>
2024-10-25 03:04:17 +03:00