Skip to content
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

[Feature Request] Stop AOD when there are no more notifications in Ambient mode #85

Closed
nahoj opened this issue Mar 22, 2023 · 4 comments · Fixed by #103
Closed

[Feature Request] Stop AOD when there are no more notifications in Ambient mode #85

nahoj opened this issue Mar 22, 2023 · 4 comments · Fixed by #103
Labels
enhancement New feature or request
Milestone

Comments

@nahoj
Copy link

nahoj commented Mar 22, 2023

I use Ambient mode ("Only show after a notification was received") to save battery.

A notification can be dealt with without using the phone. For instance, a notification for a new message in some app will disappear if I read the message on my computer.

Then AOD stays on without any notification to show. Instead, if Ambient mode is enabled, it should switch off if there are no more notifications to show.

@nahoj nahoj added the enhancement New feature or request label Mar 22, 2023
@rlees85
Copy link
Contributor

rlees85 commented Oct 30, 2023

I actually implemented this and tried it on a fork, the diff is as follows: https://gitlab.com/rlees85/alwayson/-/compare/gradleversion...notification_empty?from_project_id=51711947&straight=false

There is a side-effect, that when the AOD goes off the screen does light up for a moment (lock screen) before going off. This is because the screen is technically on whilst AOD is running and you can't tell the screen to turn off unless you are root or something like that....

For me its still better though. I don't have to keep double tapping everytime I deal with a notification elsewhere (desktop app for signal/whatsapp for example).

I also added something to stop AOD coming on for notifications that disappear before AOD even gets to know about them

edit: just to add if the maintainer was interested in a PR i'd need to figure out how to hide it behind a setting probably.

@Domi04151309 Domi04151309 added this to the 3.10.0 milestone Dec 23, 2023
@JohanAR
Copy link

JohanAR commented May 13, 2024

@rlees85 repo owner added this to a milestone, so perhaps they might be interested in a PR? I would also very much like a solution to this issue.

@Domi04151309
Copy link
Owner

I would very much be interested in a PR.
Because of limited time I sadly do not have a lot of time for developing new features myself.

@rlees85
Copy link
Contributor

rlees85 commented May 13, 2024

I will add it to my list of things (add a setting for it and then PR it). I am not really a developer though and I find Android development particularly hard and have never done settings (in a good way) before.

I may even open the PR as [WIP] or something incase anyone else wants to finish it off before I get chance too

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants