mirror of
https://github.com/Xevion/HATray.git
synced 2025-12-05 23:15:09 -06:00
17 lines
266 B
Go
17 lines
266 B
Go
package internal
|
|
|
|
import (
|
|
"fmt"
|
|
"log/slog"
|
|
"os"
|
|
)
|
|
|
|
func getIcon(icon string) []byte {
|
|
iconBytes, err := icons.ReadFile(fmt.Sprintf("resources/%s.ico", icon))
|
|
if err != nil {
|
|
slog.Error("Unable to load icon", "error", err)
|
|
os.Exit(1)
|
|
}
|
|
return iconBytes
|
|
}
|