mirror of
https://github.com/netbirdio/netbird.git
synced 2026-05-06 00:56:39 +00:00
Wails3 falls back to its bundled bird logo when no Icon is supplied via application.Options or LinuxWindow. Embed the 256x256 NetBird PNG and wire it through both fields, plus set ProgramName=netbird so GTK's g_set_prgname picks up the icon from the installed .desktop file. Tested on Fedora 40 + KDE Plasma; the titlebar and taskbar now show the NetBird logo.
55 lines
1.6 KiB
Go
55 lines
1.6 KiB
Go
//go:build !android && !ios && !freebsd && !js
|
|
|
|
package main
|
|
|
|
import _ "embed"
|
|
|
|
// Tray icons embedded from the legacy Fyne UI's asset set. Each pair is a
|
|
// light-mode PNG and its dark-mode variant; macOS template variants
|
|
// (*-macos.png) live alongside for menubar use. Windows uses the same
|
|
// PNGs — multi-resolution .ico files looked promising on disk but
|
|
// Wails3's Shell_NotifyIcon NIM_MODIFY never redrew them on the running
|
|
// tray; PNG single-frame works.
|
|
|
|
//go:embed assets/netbird-systemtray-connected.png
|
|
var iconConnected []byte
|
|
|
|
//go:embed assets/netbird-systemtray-connected-dark.png
|
|
var iconConnectedDark []byte
|
|
|
|
//go:embed assets/netbird-systemtray-disconnected.png
|
|
var iconDisconnected []byte
|
|
|
|
//go:embed assets/netbird-systemtray-connecting.png
|
|
var iconConnecting []byte
|
|
|
|
//go:embed assets/netbird-systemtray-error.png
|
|
var iconError []byte
|
|
|
|
//go:embed assets/netbird-systemtray-update-connected.png
|
|
var iconUpdateConnected []byte
|
|
|
|
//go:embed assets/netbird-systemtray-update-disconnected.png
|
|
var iconUpdateDisconnected []byte
|
|
|
|
//go:embed assets/netbird-systemtray-connected-macos.png
|
|
var iconConnectedMacOS []byte
|
|
|
|
//go:embed assets/netbird-systemtray-disconnected-macos.png
|
|
var iconDisconnectedMacOS []byte
|
|
|
|
//go:embed assets/netbird-systemtray-connecting-macos.png
|
|
var iconConnectingMacOS []byte
|
|
|
|
//go:embed assets/netbird-systemtray-error-macos.png
|
|
var iconErrorMacOS []byte
|
|
|
|
//go:embed assets/netbird-systemtray-update-connected-macos.png
|
|
var iconUpdateConnectedMacOS []byte
|
|
|
|
//go:embed assets/netbird-systemtray-update-disconnected-macos.png
|
|
var iconUpdateDisconnectedMacOS []byte
|
|
|
|
//go:embed assets/netbird.png
|
|
var iconWindow []byte
|