mirror of
https://github.com/okhsunrog/vpnhide.git
synced 2026-04-28 06:31:27 +00:00
fix(lsposed): show user-app hidden count in save snackbar (#88)
The post-save snackbar was reading hiddenPkgs.size, but hiddenPkgs has
selfPkg appended unconditionally (so the kernel-side list always
contains vpnhide itself), so the displayed count was always one higher
than what the user actually selected.
Switch to the same hiddenCount/observerCount values the screen header
already uses (allApps.count { it.hidden / it.observer }) so both
counters stay in sync and don't drift if the hiddenPkgs assembly logic
changes again.
Closes #79.
This commit is contained in:
parent
06640d9b16
commit
41342e51e8
2 changed files with 10 additions and 1 deletions
|
|
@ -0,0 +1,9 @@
|
|||
_2026-04-25_
|
||||
|
||||
## English
|
||||
|
||||
Save snackbar on the App Hiding screen no longer counts vpnhide itself in the hidden total.
|
||||
|
||||
## Русский
|
||||
|
||||
Snackbar после сохранения на экране скрытия приложений больше не учитывает сам vpnhide в счётчике скрытых.
|
||||
|
|
@ -341,7 +341,7 @@ fun AppHidingScreen(
|
|||
suExecAsync(buildHidingSaveCommand(header, hiddenPkgs, observerPkgs))
|
||||
if (exitCode == 0) {
|
||||
snackMessage =
|
||||
context.getString(R.string.hiding_save_success, hiddenPkgs.size, observerPkgs.size)
|
||||
context.getString(R.string.hiding_save_success, hiddenCount, observerCount)
|
||||
DashboardCache.invalidate()
|
||||
TargetsCache.refresh(scope, context)
|
||||
} else if (exitCode == -1) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue