-
Notifications
You must be signed in to change notification settings - Fork 258
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
feat: implement showNotificationsCountInTray
setting
#780
feat: implement showNotificationsCountInTray
setting
#780
Conversation
77a5481
to
872f2b7
Compare
Hello @setchy, sorry for tagging you but this PR has been here for 45 days and didn't receive a single comment 😢 I think this could be a really great addition to Gitify ; please let me know what you think! |
I'll take a look during the week @adufr - we have been quite preoccupied with getting v5 out. |
Yeah I can imagine, congrats on that! You've done quite some work and the app looks much better now! 😁 |
On initial glance, it seems like a lot of files have changes. Is there a simpler path here to access the settings? |
@setchy I agree, but I didn't find any other way to make it work 😕 |
I fixed all conflicts following 5.1.0 release |
Do not hesitate to ping me once it's merged, I can probably rewrite the feature |
superseded by #945 |
Related issues
#750
Context
Introduce a new setting (disabled by default), that uses the
tray.setTitle()
API to show the notifications count next to the tray icon.Discussion
There are quite a lot of changes because I had to pass
settings
into a few methods so that theupdateTrayIcon()
method could inherit them, as it now requires them.It's also quite the mess in the
ipcMain.on('update-icon')
event handler, as I had to make sure the icon was refreshed whenever you enable/disable the setting, without losing the notifications count, which is not passed to the function it's not in the scope. (That's why props ofupdateTrayIcon()
are optional)If you have suggestions to make the implementation easier, please let me know.
I tried implementing some tests, I wanted to use the
tray.getTitle()
method to add more, but it looks like there's nowhere I could access thetray
in the tests...