Skip to content

feat: Add Android 16 progress-centric notifications (Live Activities)#359

Open
eggmasonvalue wants to merge 1 commit intomueller-ma:mainfrom
eggmasonvalue:feature/android-16-live-activities
Open

feat: Add Android 16 progress-centric notifications (Live Activities)#359
eggmasonvalue wants to merge 1 commit intomueller-ma:mainfrom
eggmasonvalue:feature/android-16-live-activities

Conversation

@eggmasonvalue
Copy link

This PR adds support for Android 16's new Progress-centric Notifications. It provides a rich, interactive notification showing real-time wake-lock status and timer countdown, including a status bar chip on supported devices.

Key Changes:

  • Added ProgressNotificationManager to handle Android 16+ specific notification logic.
  • Integrated with ForegroundService with full backward compatibility check (SDK_INT >= 36).
  • Added POST_PROMOTED_NOTIFICATIONS permission for Live Update visibility.
  • Added a toggle in settings to enable/disable the feature (hidden on older Android versions).

@mueller-ma
Copy link
Owner

I'm not sure if this is a valid use-case for the new notifications. Google says:

Key use cases include rideshare, delivery, and navigation. Within the Notification.ProgressStyle class, you can denote states and milestones in a user journey using points and segments.

https://developer.android.com/about/versions/16/features/progress-centric-notifications

I don't think there's a real progress, so it seems wrong to me to show some kind of progress indicator to the user. At the end Coffee just stops.

@eggmasonvalue
Copy link
Author

Hi, this page details usage in a bit more details and this change isn't violating any guidelines here.

Examples here include "starting a workout" which in most cases is a simple timer

"Time Sensitive
Show a Live Update only if it requires the user's attention throughout the activity. A key use case for Live Updates is monitoring, when the user gets significant benefit from glancing at the Live Update to keep an eye on the evolving state of the activity."

And personally, the reason I use this is that there's an unbelievable improvement in my experience of using this app merely because of the status chip giving me glanceable information on how long the screen will remain turned on.

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