-
-
Notifications
You must be signed in to change notification settings - Fork 7
feat: Foldable support, Edge-to-Edge, and Fixes #13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
fcc28f4
Refactor: Extract PolicyAccessDialog into its own file
KoukeNeko 6fbb698
feat: Add bottom navigation
KoukeNeko 86147f8
fix: Stop service when no locks are set
KoukeNeko 9fa8787
feat: Add tablet layout
KoukeNeko 1b1e2ce
feat: Add about screen and improve UI
KoukeNeko f788e90
chore: Update gitignore
KoukeNeko 38ac8be
refactor: Improve password dialog
KoukeNeko 3a23ed9
chore: Use standard AlertDialog
KoukeNeko 84ec545
fix: Resolve stopForeground issues and clean up strings
KoukeNeko af5c027
fix: Prevent service start on boot if no locks active
KoukeNeko c09613d
refactor: Use resource-based layout logic and safe fragment commit
KoukeNeko 59b9d82
refactor: Use MaterialAlertDialogBuilder for password dialogs
KoukeNeko 351829b
feat: Add password validation and encrypted storage
KoukeNeko c3354fc
fix: Resolve detekt lint issues
KoukeNeko b391937
fix: Stop service when last volume lock is removed
KoukeNeko File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,5 @@ | ||
| .idea | ||
| .gradle | ||
| local.properties | ||
| build/ | ||
| .kotlin/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
57 changes: 57 additions & 0 deletions
57
app/src/main/java/com/klee/volumelockr/ui/AboutFragment.kt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,57 @@ | ||
| package com.klee.volumelockr.ui | ||
|
|
||
| import android.os.Bundle | ||
| import android.view.LayoutInflater | ||
| import android.view.View | ||
| import android.view.ViewGroup | ||
| import androidx.fragment.app.Fragment | ||
| import androidx.recyclerview.widget.GridLayoutManager | ||
| import androidx.recyclerview.widget.RecyclerView | ||
| import com.klee.volumelockr.R | ||
| import com.mikepenz.aboutlibraries.LibsBuilder | ||
|
|
||
| class AboutFragment : Fragment() { | ||
|
|
||
| override fun onCreateView( | ||
| inflater: LayoutInflater, | ||
| container: ViewGroup?, | ||
| savedInstanceState: Bundle? | ||
| ): View { | ||
| return inflater.inflate(R.layout.fragment_about, container, false) | ||
| } | ||
|
|
||
| override fun onViewCreated(view: View, savedInstanceState: Bundle?) { | ||
| super.onViewCreated(view, savedInstanceState) | ||
|
|
||
| if (savedInstanceState == null) { | ||
| val libsFragment = LibsBuilder() | ||
| .supportFragment() | ||
|
|
||
| childFragmentManager.beginTransaction() | ||
| .add(R.id.about_libs_container, libsFragment) | ||
| .commit() | ||
| } | ||
|
|
||
| view.post { | ||
| val recyclerView = findRecyclerView(view) | ||
| recyclerView?.let { rv -> | ||
| val spanCount = if (resources.getBoolean(R.bool.use_two_columns)) 2 else 1 | ||
| if (spanCount > 1) { | ||
| rv.layoutManager = GridLayoutManager(requireContext(), spanCount) | ||
| } | ||
| } | ||
| } | ||
| } | ||
|
|
||
| private fun findRecyclerView(view: View): RecyclerView? { | ||
| if (view is RecyclerView) return view | ||
| if (view is ViewGroup) { | ||
| for (i in 0 until view.childCount) { | ||
| val child = view.getChildAt(i) | ||
| val rv = findRecyclerView(child) | ||
| if (rv != null) return rv | ||
| } | ||
| } | ||
| return null | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
app/src/main/java/com/klee/volumelockr/ui/PolicyAccessDialog.kt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| package com.klee.volumelockr.ui | ||
|
|
||
| import android.app.AlertDialog | ||
| import android.app.Dialog | ||
| import android.content.Intent | ||
| import android.os.Build | ||
| import android.os.Bundle | ||
| import android.provider.Settings | ||
| import androidx.annotation.RequiresApi | ||
| import androidx.fragment.app.DialogFragment | ||
| import com.klee.volumelockr.R | ||
|
|
||
| class PolicyAccessDialog : DialogFragment() { | ||
| companion object { | ||
| const val TAG = "PolicyAccessDialog" | ||
| } | ||
|
|
||
| @RequiresApi(Build.VERSION_CODES.M) | ||
| override fun onCreateDialog(savedInstanceState: Bundle?): Dialog = | ||
| AlertDialog.Builder(requireContext()) | ||
| .setMessage(getString(R.string.dialog_policy_access_title)) | ||
| .setCancelable(false) | ||
| .setPositiveButton(getString(R.string.dialog_allow)) { _, _ -> | ||
| startActivity(Intent(Settings.ACTION_NOTIFICATION_POLICY_ACCESS_SETTINGS)) | ||
| } | ||
| .create() | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🌐 Web query:
androidx.security security-crypto latest stable version 1.1.0-alpha06 production ready💡 Result:
No — 1.1.0-alpha06 is an alpha (pre‑release) and not intended for production. The stable 1.1.0 release was published on July 30, 2025; prefer that (or a later stable) for production. Note: the security-crypto artifacts have been marked deprecated — consider following the deprecation guidance in the release notes. [1][2]
Sources:
[1] AndroidX Security release notes (shows 1.1.0 release on July 30, 2025 and alpha/rc history).
[2] AndroidX versions/all-channel & deprecation note for security-crypto.
🏁 Script executed:
Repository: jonathanklee/VolumeLockr
Length of output: 129
🏁 Script executed:
Repository: jonathanklee/VolumeLockr
Length of output: 387
🏁 Script executed:
Repository: jonathanklee/VolumeLockr
Length of output: 199
Upgrade security-crypto version and address library deprecation.
The dependency uses version
1.1.0-alpha06, an alpha pre-release. A stable version1.1.0has been available since July 30, 2025 and should be used for production.More importantly,
androidx.security:security-cryptohas been deprecated. Follow the deprecation guidance in the AndroidX Security release notes to migrate to the recommended alternative.Update
gradle/libs.versions.tomlline withsecurityCrypto = "1.1.0"at minimum, and plan migration away from the deprecated library.