Commit 50bddb1
New Settings and Biometric Auth (#137)
* Shizuku and Dhizuku app installer Stability fix (#131)
* Update project inspection profiles and build configuration
* **IDE**: Extensively expanded `Project_Default.xml` with numerous Android Lint inspection tools, specifically covering Accessibility, Jetpack Compose, Fragments, and various Google Play policies.
* **Build**: Updated `app/build.gradle.kts` to exclude dependency information from APKs while retaining it in App Bundles.
* chore(deps): bump com.google.devtools.ksp in the maven group (#128)
Bumps the maven group with 1 update: [com.google.devtools.ksp](https://github.com/google/ksp).
Updates `com.google.devtools.ksp` from 2.3.5 to 2.3.6
- [Release notes](https://github.com/google/ksp/releases)
- [Commits](google/ksp@2.3.5...2.3.6)
---
updated-dependencies:
- dependency-name: com.google.devtools.ksp
dependency-version: 2.3.6
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: maven
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* chore(deps): bump the maven group with 2 updates (#129)
Bumps the maven group with 2 updates: com.android.application and com.android.test.
Updates `com.android.application` from 9.1.0-alpha09 to 9.2.0-alpha01
Updates `com.android.test` from 9.1.0-alpha09 to 9.2.0-alpha01
Updates `com.android.test` from 9.1.0-alpha09 to 9.2.0-alpha01
---
updated-dependencies:
- dependency-name: com.android.application
dependency-version: 9.2.0-alpha01
dependency-type: direct:production
update-type: version-update:semver-minor
dependency-group: maven
- dependency-name: com.android.test
dependency-version: 9.2.0-alpha01
dependency-type: direct:production
update-type: version-update:semver-minor
dependency-group: maven
- dependency-name: com.android.test
dependency-version: 9.2.0-alpha01
dependency-type: direct:production
update-type: version-update:semver-minor
dependency-group: maven
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Revise APK size details and add support options
Updated download sizes and added support development section.
* Add Ko-fi funding option to FUNDING.yml
add ko-fi and patreon
* Clean up project dependencies by removing benchmarking and profiling libraries
* **Build**: Remove unused versions and library definitions for `annotationJvm`, `uiautomator`, `benchmarkMacroJunit4`, `baselineprofile`, and `profileinstaller` from `gradle/libs.versions.toml`.
* Clean up project-level build configuration and plugin definitions
* **Build**: Remove unused `kotlin-android` and `baselineprofile` plugin definitions from `gradle/libs.versions.toml`.
* **Build**: Remove the commented-out `kotlin.android` plugin alias from the top-level `build.gradle.kts`.
* Enhance Shizuku/Dhizuku installer stability and fallbacks
* **Build**: Bump `versionCode` to 1715 and `versionName` to 1.71.5 in `gradle.properties`.
* **Installer**:
* Implement a silent fallback mechanism in `InstallerRepositoryImpl` that reverts to the system's default `PackageInstaller` if Shizuku or Dhizuku privileged installations fail.
* Refactor `getDhizukuPackageInstaller` and `getShizukuPackageInstaller` to use `ShizukuPackageInstallerUtils` for better compatibility across API levels and ROMs, avoiding `NoSuchMethodError` on certain devices.
* Ensure created installation sessions belong to the app's own package name to prevent UID mismatch errors.
* Add `emitErrors` flag to `performPackageInstallerInstall` to allow internal retries without triggering error UI states prematurely.
* **ShizukuReflector**: Add `createPackageInstallerFor(installerPackageName)` to allow creating privileged installers for specific package identities.
* **IDE**: Clean up `Project_Default.xml` by removing numerous explicit Android Lint inspection rules.
---------
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Trinadh Thatakula <YOUR_EMAIL_HERE>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* New Settings page (#135)
* chore(deps): bump io.coil-kt.coil3:coil-compose in the maven group (#132)
Bumps the maven group with 1 update: [io.coil-kt.coil3:coil-compose](https://github.com/coil-kt/coil).
Updates `io.coil-kt.coil3:coil-compose` from 3.3.0 to 3.4.0
- [Release notes](https://github.com/coil-kt/coil/releases)
- [Changelog](https://github.com/coil-kt/coil/blob/main/CHANGELOG.md)
- [Commits](coil-kt/coil@3.3.0...3.4.0)
---
updated-dependencies:
- dependency-name: io.coil-kt.coil3:coil-compose
dependency-version: 3.4.0
dependency-type: direct:production
update-type: version-update:semver-minor
dependency-group: maven
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* chore(deps): bump the maven group across 1 directory with 3 updates (#134)
Bumps the maven group with 3 updates in the / directory: androidx.compose.material3:material3, com.android.application and com.android.test.
Updates `androidx.compose.material3:material3` from 1.5.0-alpha14 to 1.5.0-alpha15
Updates `com.android.application` from 9.2.0-alpha01 to 9.2.0-alpha02
Updates `com.android.test` from 9.2.0-alpha01 to 9.2.0-alpha02
Updates `com.android.test` from 9.2.0-alpha01 to 9.2.0-alpha02
---
updated-dependencies:
- dependency-name: androidx.compose.material3:material3
dependency-version: 1.5.0-alpha15
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: maven
- dependency-name: com.android.application
dependency-version: 9.2.0-alpha02
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: maven
- dependency-name: com.android.test
dependency-version: 9.2.0-alpha02
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: maven
- dependency-name: com.android.test
dependency-version: 9.2.0-alpha02
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: maven
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Update Gradle wrapper to 9.4.0-rc-1
* Update `distributionUrl` to Gradle 9.4.0-rc-1 in `gradle-wrapper.properties`.
* Add `distributionSha256Sum` for the new Gradle distribution.
* Add AndroidX Biometric dependency
* **Build**: Add `androidx.biometric:biometric-ktx` version `1.2.0-alpha05` to `gradle/libs.versions.toml`.
* **App**: Include `libs.androidx.biometric` as an implementation dependency in `app/build.gradle.kts`.
* Implement biometric authentication and expanded user preferences
* **Core**: Add `BiometricHelper` utility to check for biometric hardware and authentication capabilities using `androidx.biometric`.
* **Preferences**:
* Expand `UserPreferences` and `PreferenceRepository` to support `ThemeMode`, `useDynamicColor`, and `biometricLockEnabled`.
* Refactor `PreferenceRepositoryImpl` to use `runCatching` for safer enum parsing and organize keys into logical groups (App List, Theme, Security).
* **Security UI**:
* Implement `BiometricScreen` to handle the transition between the system biometric prompt and a custom `BiometricErrorScreen`.
* Add `AuthState` sealed interface to manage the application's authentication lifecycle (NotRequired, Locked, Unlocked, Error).
* Use `FragmentActivity` for hosting `BiometricPrompt` and provide a Material Expressive error UI with retry/exit actions.
* Add SettingsViewModel and initial SettingsScreen with ThemeMode domain model
* **Domain**: Add `ThemeMode` enum to represent Light, Dark, and System theme preferences with associated labels.
* **Presentation**:
* Implement `SettingsViewModel` to manage user preferences (theme mode, dynamic color, and biometric lock) and interface with `BiometricHelper` for hardware capability checks.
* Create a placeholder `SettingsScreen` composable integrated with Koin for view model injection.
* Add Settings screen and biometric authentication support
* **Navigation**: Enable the `SETTINGS` destination in `AppDestinations.kt` and integrate `SettingsScreen` into the `MainScreen` navigation logic.
* **Security**:
* Implement `SecurityViewModel` to manage session-based authentication states (`Locked`, `Unlocked`, `Error`, `NotRequired`).
* Add `BiometricHelper` to the dependency injection `coreModule`.
* Update `HomeActivity` to conditionally display a `BiometricScreen` based on the current authentication state before granting access to the `MainScreen`.
* **Preferences**: Expand `UserPreferences` to include settings for `themeMode`, `useDynamicColor`, and `biometricLockEnabled`.
* **Dependency Injection**: Register `SettingsViewModel`, `SecurityViewModel`, and `BiometricHelper` in `Modules.kt`.
* **Code Cleanup**: Remove redundant comments regarding Shizuku permission handling in `HomeActivity`.
* Add UI components and building blocks for Settings screen
* **UI Components**: Implement reusable Composable functions for the settings interface:
* `SettingsHeader`: Displays a header with an icon and "Settings" title.
* `SettingsSectionLabel` and `SettingsDivider`: Provides visual separation for setting groups.
* `SettingsRow`: A base layout for setting items with an icon, title, and subtitle.
* `SettingsSwitchRow`: A specialized row containing a toggle switch.
* `SettingsInfoRow`: A row for displaying static key-value information.
* `SettingsLinkRow`: A row with an action button for external links.
* `EnrollBiometricRow`: A specific action row for directing users to system biometric settings.
* Introduce `ConnectedButtonGroup` component and refactor UI selection controls
* **Components**: Create `ConnectedButtonGroup`, a reusable selection component built on Material 3 Expressive APIs (`ButtonGroup` and `ToggleButton`) that supports animated width transitions and custom item types (Icon, Label, or both).
* **UI Refactoring**: Replace `SingleChoiceSegmentedButtonRow` and `SegmentedButton` with the new `ConnectedButtonGroup` across multiple screens for a more consistent and animated experience:
* `SettingsScreen`: Updated theme mode selection.
* `AppListScreen` & `FreezerScreen`: Updated app type switcher (User/System).
* `DashboardHeader`: Updated app type switcher.
* `AppFilterSheet`: Updated tab selection (Filters/Sort).
* **Security**: Wrap `BiometricScreen` content in a `Scaffold` and `Box` to ensure proper layout and padding.
* **Navigation**: Fix a duplicate `SettingsScreen` entry in `MainScreen`'s destination logic.
* **Activity**: Update `HomeActivity` to inherit from `FragmentActivity` instead of `ComponentActivity` to support fragment-based APIs (likely for biometric integration).
* Update theme handling in HomeActivity and adjust versioning in gradle.properties
* Update theme settings icon in SettingsScreen
* **UI**: Update the `SettingsRow` for the "Theme" option in `SettingsScreen.kt` to use the new `theme_panel` icon instead of the shield icon.
* **Resources**: Add `app/src/main/res/drawable/theme_panel.xml`, a new vector drawable representing a color palette/theme panel.
* Add AMOLED mode support for pure black background in dark theme
* **UI**: Add "AMOLED Mode" switch to `SettingsScreen` with a description for pure black backgrounds.
* **Theme**: Update `ThorTheme` to override background and surface colors to pure black when `amoledMode` and `darkTheme` are enabled.
* **Domain**: Add `useAmoled` property to `UserPreferences` and define `setUseAmoled` in `PreferenceRepository`.
* **Data**: Implement `USE_AMOLED` DataStore key and persistence logic in `PreferenceRepositoryImpl`.
* **Integration**: Update `SettingsViewModel` to handle AMOLED toggle and `HomeActivity` to pass the preference to the theme engine.
* Update app/src/main/java/com/valhalla/thor/HomeActivity.kt
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
* Update app/src/main/java/com/valhalla/thor/presentation/main/MainScreen.kt
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Fix review feedback: compilation errors, auth flicker, dead file, Gradle RC (#136)
* Initial plan
* Address all open review comments from Settings page PR
Co-authored-by: trinadhthatakula <33689525+trinadhthatakula@users.noreply.github.com>
* Revert Gradle wrapper back to 9.4.0-rc-1 (9.4 stable not yet released)
Co-authored-by: trinadhthatakula <33689525+trinadhthatakula@users.noreply.github.com>
* Apply suggestion from @Copilot
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: trinadhthatakula <33689525+trinadhthatakula@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Remove distribution SHA-256 sum from Gradle wrapper
* Remove the `distributionSha256Sum` property from `gradle/wrapper/gradle-wrapper.properties`.
* Update app/src/main/java/com/valhalla/thor/presentation/security/BiometricPromptHandler.kt
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update app/src/main/java/com/valhalla/thor/presentation/common/components/ConnectedButtonGroup.kt
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
---------
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Trinadh Thatakula <YOUR_EMAIL_HERE>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
* Clean up redundant code and imports in UI and security components
* **UI**: Remove unused `Spacer`, `width`, and `animateWidth` imports from `ConnectedButtonGroup.kt`.
* **UI**: Remove duplicate `@OptIn` and `@Composable` annotations from the `connectedShapesFor` function in `ConnectedButtonGroup.kt`.
* **Security**: Remove a duplicate `BiometricPromptHandler` object declaration and its associated KDoc in `BiometricPromptHandler.kt`.
* Update README to reflect Fingerprint Lock status
Removed Fingerprint Lock from upcoming features and added it to working features.
* Update app/src/main/java/com/valhalla/thor/data/repository/InstallerRepositoryImpl.kt
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
---------
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Trinadh Thatakula <YOUR_EMAIL_HERE>1 parent 58ece4f commit 50bddb1
File tree
31 files changed
+1357
-166
lines changed- .github
- app
- src/main
- java/com/valhalla/thor
- data
- repository
- security
- source/local/shizuku
- di
- domain
- model
- repository
- presentation
- appList
- common/components
- freezer
- home
- components
- main
- security
- settings
- theme
- widgets
- res/drawable
- gradle
- wrapper
31 files changed
+1357
-166
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | | - | |
3 | 1 | | |
4 | 2 | | |
| 3 | + | |
5 | 4 | | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
32 | | - | |
| 31 | + | |
| 32 | + | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
39 | | - | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
40 | 43 | | |
41 | 44 | | |
42 | 45 | | |
| |||
61 | 64 | | |
62 | 65 | | |
63 | 66 | | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
64 | 77 | | |
65 | 78 | | |
66 | 79 | | |
| |||
80 | 93 | | |
81 | 94 | | |
82 | 95 | | |
83 | | - | |
| 96 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
97 | 97 | | |
98 | 98 | | |
99 | 99 | | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
100 | 105 | | |
101 | 106 | | |
102 | 107 | | |
| |||
188 | 193 | | |
189 | 194 | | |
190 | 195 | | |
| 196 | + | |
191 | 197 | | |
192 | 198 | | |
193 | 199 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
5 | 4 | | |
6 | 5 | | |
| 6 | + | |
| 7 | + | |
7 | 8 | | |
| 9 | + | |
| 10 | + | |
8 | 11 | | |
| 12 | + | |
9 | 13 | | |
10 | 14 | | |
11 | 15 | | |
12 | 16 | | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
13 | 21 | | |
14 | 22 | | |
15 | 23 | | |
16 | 24 | | |
17 | 25 | | |
18 | 26 | | |
19 | | - | |
| 27 | + | |
20 | 28 | | |
21 | 29 | | |
22 | 30 | | |
| 31 | + | |
| 32 | + | |
23 | 33 | | |
24 | 34 | | |
25 | 35 | | |
| |||
31 | 41 | | |
32 | 42 | | |
33 | 43 | | |
34 | | - | |
35 | 44 | | |
36 | 45 | | |
37 | 46 | | |
| |||
42 | 51 | | |
43 | 52 | | |
44 | 53 | | |
45 | | - | |
46 | 54 | | |
47 | 55 | | |
48 | 56 | | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
54 | 96 | | |
55 | 97 | | |
56 | 98 | | |
57 | 99 | | |
58 | 100 | | |
59 | 101 | | |
60 | 102 | | |
61 | | - | |
62 | 103 | | |
63 | 104 | | |
64 | 105 | | |
| |||
70 | 111 | | |
71 | 112 | | |
72 | 113 | | |
73 | | - | |
| 114 | + | |
0 commit comments