Fleet desktop: On Windows, replace light/dark icons with colorful icon (#13457)

This commit is contained in:
Jacob Shandling 2023-08-24 10:03:54 -07:00 committed by GitHub
parent 5c7019cfc4
commit 54e6ffd61b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions

View file

@ -0,0 +1 @@
* Replace the black and white Fleet desktop icons with a single colorful icon on Windows.

View file

@ -18,10 +18,12 @@ import (
// For Windows we must use ico format for the icon,
// see https://github.com/getlantern/systray/blob/6065fda28be8c8d91aeb5e20de25e1600b8664a3/systray_windows.go#L850-L856.
//go:embed icon_light.ico
// since watchSystemTheme is currently buggy, we are using the same icon for both themes
//
//go:embed windows_app.ico
var iconLight []byte
//go:embed icon_dark.ico
//go:embed windows_app.ico
var iconDark []byte
// Adapted from MIT licensed code in
@ -63,6 +65,7 @@ func getSystemTheme() (theme, error) {
}
}
// since this logic is currently buggy, we are currently using the same icon for both themes
func watchSystemTheme(iconManager *iconManager) {
for {
// Function call for proper defer semantics.