Skip to content

fix: add a default icon to notifications on linux#4283

Merged
lucasfernog merged 2 commits into
tauri-apps:devfrom
betamos:linux-notification-icon
Jun 9, 2022
Merged

fix: add a default icon to notifications on linux#4283
lucasfernog merged 2 commits into
tauri-apps:devfrom
betamos:linux-notification-icon

Conversation

@betamos
Copy link
Copy Markdown
Contributor

@betamos betamos commented Jun 7, 2022

Currently, the notification api allows an optional icon. This has no effect on Windows and MacOS, where the icon is always taken from the application. This change has no effect on those platforms, but sets a default icon based on the binary path, which ensures notifications, by default, uses the app's icon.

This icon is also shown in dev mode if the app is installed. Otherwise, it just displays no icon.

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Docs
  • New Binding issue #___
  • Code style update
  • Refactor
  • Build-related changes
  • Other, please describe:

Does this PR introduce a breaking change?

  • Yes, and the changes were approved in issue #___
  • No

Checklist

  • When resolving issues, they are referenced in the PR's title (e.g fix: remove a typo, closes #___, #___)
  • A change file is added if any packages will require a version bump due to this PR per the instructions in the readme.
  • I have added a convincing reason for adding this feature, if necessary

Other information

@betamos betamos requested a review from a team June 7, 2022 02:27
Comment thread core/tauri/src/endpoints/notification.rs Outdated
Copy link
Copy Markdown
Member

@lucasfernog lucasfernog left a comment

Choose a reason for hiding this comment

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

Please add a change file, check out the .changes folder to see how to do it. Basically:

---
"tauri": patch
---

Set notification icon to app icon on Linux.

@betamos betamos force-pushed the linux-notification-icon branch from 72abaac to 660d972 Compare June 7, 2022 18:27
@betamos betamos requested a review from a team as a code owner June 7, 2022 18:29
@lucasfernog lucasfernog merged commit 235e448 into tauri-apps:dev Jun 9, 2022
@betamos betamos deleted the linux-notification-icon branch June 10, 2022 17:49
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