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

refactor: ginify Notification #22821

Merged
merged 5 commits into from
Mar 31, 2020
Merged

refactor: ginify Notification #22821

merged 5 commits into from
Mar 31, 2020

Conversation

nornagon
Copy link
Member

Description of Change

Also, add some tests.

Checklist

Release Notes

Notes: none

@electron-cation electron-cation bot added the new-pr 🌱 PR opened in the last 24 hours label Mar 24, 2020
@nornagon
Copy link
Member Author

cc @sethlu

Copy link
Member

@zcbenz zcbenz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add code to ensure the notification object is destroyed/cleared on exit?

It is a problem with Windows 10 that, if you don't clear the notification it would stay in the list even when it does not meant to.

@electron-cation electron-cation bot removed the new-pr 🌱 PR opened in the last 24 hours label Mar 25, 2020
@nornagon
Copy link
Member Author

@zcbenz hmm, that seems like it might be the intended behavior on Windows in the underlying API?

If an app crashes, it won't be able to call any OS functions to remove notifications.

@zcbenz
Copy link
Member

zcbenz commented Mar 26, 2020

It think this is similar to Tray icons, it is fine to leave a ghost icon there if the process crashed, but it should clear the icon if it exited normally.

But anyway I tried to find out the original issue about this but didn't succeed, let's just leave it leaked on exit.

@zcbenz
Copy link
Member

zcbenz commented Mar 26, 2020

Also I think this should be marked as feat and documented for the same reason with #22822 (comment).

@nornagon

This comment has been minimized.

@nornagon
Copy link
Member Author

NB this removes the .destroy method from Notification, because it's not documented and not tested.

@nornagon nornagon requested a review from zcbenz March 30, 2020 23:29
@nornagon nornagon merged commit 765c08c into master Mar 31, 2020
@release-clerk
Copy link

release-clerk bot commented Mar 31, 2020

No Release Notes

@nornagon nornagon deleted the ginify-notification branch March 31, 2020 18:42
sentialx pushed a commit to sentialx/electron that referenced this pull request Apr 7, 2020
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.

None yet

2 participants