Home

thomasboom / yam-launcher

public
Overview Code History Branches Pull requestsIssuesInsights
main
HomeOverview Code PRsIssues

feat: Implement biometric lock for settings and improve code readability

last year

bec7506
Authored
CreativeCodeCat4/21/2025, 6:27:09 PM
This commit introduces a biometric lock feature for the settings in YAM Launcher, enhancing security. Users can now choose to lock their settings, requiring biometric authentication (fingerprint, face ID, etc.) to access them.

Key changes include:

- Added a "Lock Settings" switch preference in the settings menu.
- Implemented biometric authentication using the BiometricPrompt API.
- Modified the settings access logic in MainActivity to check the lock status and initiate biometric authentication if necessary.
- Added BiometricUtils class to encapsulate biometric authentication logic.
- Updated dependencies in build.gradle.kts to use Java 17 and compile SDK 36.
- Improved code readability by using Kotlin's apply and edit extension functions for SharedPreferences, and by adding KTX dependencies.

Parent51df645

7 files changed
  • app/build.gradle.kts+5−6
  • app/src/main/AndroidManifest.xml+2−1
  • app/src/main/java/eu/ottop/yamlauncher/MainActivity.kt+163−63
  • app/src/main/java/eu/ottop/yamlauncher/settings/SharedPreferenceManager.kt+64−58
  • app/src/main/java/eu/ottop/yamlauncher/utils/BiometricUtils.kt+54−0
  • app/src/main/res/values/strings.xml+9−0
  • app/src/main/res/xml/root_preferences.xml+7−0