Skip to content

Add toggle to hide the status bar mute icon on Android 17 QPR1+ - #961

Open
mbahakeskin wants to merge 1 commit into
Mahmud0808:betafrom
mbahakeskin:hide-statusbar-mute-icon
Open

mbahakeskin wants to merge 1 commit into
Mahmud0808:betafrom
mbahakeskin:hide-statusbar-mute-icon

Conversation

@mbahakeskin

Copy link
Copy Markdown

Android 17 QPR1 moved status bar icon rendering to a new Compose-based pipeline (behind the status_bar_root_modernization and status_bar_system_status_icons_in_compose aconfig flags, both enabled and read-only on release builds). The old icon_blacklist Secure setting that StatusbarMisc previously relied on for hiding things like the mute icon is no longer read by this new pipeline.

I found that the new code (HomeStatusBarIconBlockListInteractor) reads a separate, dedicated Secure setting for the mute icon: status_bar_show_mute_icon (0 hides it, default is shown). SystemUI observes this reactively, so writing it takes effect immediately, no restart needed.

This adds a "Hide Mute Icon" switch under Statusbar > Icon Visibility. It writes status_bar_show_mute_icon from inside the SystemUI hook (mContext there is SystemUI's own context, which already holds WRITE_SECURE_SETTINGS), the same approach StatusbarMisc already uses for the lockscreen carrier/statusbar hiding.

I don't see an equivalent setting for Bluetooth yet on QPR1. QPR2 Beta 4 adds a new BluetoothIconViewModel, but its visibility is computed purely from Bluetooth connection state, no settings-backed toggle. Might be worth revisiting once that lands in a stable release.

Compiled clean (compileFossDebugKotlin), but I don't have an LSPosed test rig handy, so this hasn't been verified on-device. Happy to adjust if something's off.

@Mahmud0808

Copy link
Copy Markdown
Owner

Thanks for the PR. I think we should gate this setting behind an Android 17 check so that it isn't shown to Android 16 users.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants