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

Suggestion: Charge state-dependent notifications #19

Open
Lord-Memester opened this issue May 25, 2024 · 6 comments
Open

Suggestion: Charge state-dependent notifications #19

Lord-Memester opened this issue May 25, 2024 · 6 comments
Assignees
Labels
bug Something isn't working documentation Improvements or additions to documentation enhancement New feature or request

Comments

@Lord-Memester
Copy link

I would like more options for when the program sends notifications.

For example, I have a notification set for when the battery is at 30%.

  • When my laptop is discharging and gets to 30%, sending me a notification is really useful, and lets me know to charge it.
  • If my laptop is at 27% and while charging it reaches 30%, I don't feel the need to know, since I plan to just keep charging it past that point.

So a setting of being notified while charging, while discharging, or both for each of the individual user-specified notification-associated percentages would be greatly appreciated.

@medhachaitanya
Copy link
Owner

I completely agree. I'm currently working on making it simpler. You can now add any desired percentage, using a minus symbol (-) to indicate discharging.

For example:

  • Example 1: -30, -50, 80, 85 will show notifications at 30% and 50% when discharging, and at 80% and 85% when charging.
  • Example 2: -30, 90 will show notifications at 30% when discharging and at 90% when charging.
  • Example 3: -30, 30, 90 will show notifications at 30% when discharging and at 30%, 90% when charging.

In summary, using the minus symbol (-) specifies that the notification should be shown when the battery is discharging.

@Lord-Memester
Copy link
Author

Lord-Memester commented May 26, 2024

Excellent! An additional suggestion to consider:

  • - is used as you suggested.
  • + prepended to a value will notify only when charging.
  • if nothing is prepended to the value, notify on both charging and discharging
  • if -+ or +- is prepended, either disallow this in the program and pop up a warning (like when you try to name a file with invalid characters in windows) or have it notify on both charging and discharging

I would personally find this preferable, as it would do away with the need for double entry of values and would visually make more sense. It would also be easy to include a short guide for in the window, like below:


Default behavior is to notify upon being charged to and discharged to any provided value.

For more precise control, prepend:

  • - to notify when discharged to the value
  • + to notify when charged to the value

@medhachaitanya
Copy link
Owner

I like it. Thanks for sharing. I released a build for the aforementioned feature already. I will squeeze some time to work on the new suggestion soon.

@Lord-Memester
Copy link
Author

I like it. Thanks for sharing. I released a build for the aforementioned feature already. I will squeeze some time to work on the new suggestion soon.

I must say, I cannot find this build. I assume this has been made part of the Pure Battery Percentage Add-On, but this repository hasn't been updated (had any commits) since last year, and I can find no new release on the Microsoft Store when I check for updates.

@medhachaitanya
Copy link
Owner

medhachaitanya commented May 26, 2024 via email

@Lord-Memester
Copy link
Author

Lord-Memester commented May 27, 2024

It's still under processing. You will get a Microsoft store update sometime in the next couple of hours.

I've gotten the update now! Found an issue though:

A space between the comma and the number registers as an invalid entry, which is contrary to the example of (-30, 90) described in the window.
image (-30, 50)
image (-30, -50)

If we remove the space, it registers as valid.
image (-30,50)
image (-30,-50)

The entry with a space between seems to be the intended method, so this needs to be fixed.

@medhachaitanya medhachaitanya self-assigned this May 27, 2024
@medhachaitanya medhachaitanya added bug Something isn't working enhancement New feature or request documentation Improvements or additions to documentation labels May 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants