Files
syncwarden/cmd/panel/main.go
Axel Meyer 11e5c9b915
All checks were successful
Release / build (push) Successful in 2m34s
Set window icon on Admin Panel (title bar + taskbar)
Embed the blue SyncWarden shield icon in the panel binary and set it
as the window icon via Win32 SendMessage/WM_SETICON on startup.
Uses the syncing (blue) variant as the status-independent panel icon.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 23:26:11 +01:00

29 lines
465 B
Go

package main
import (
"flag"
"log"
"github.com/webview/webview_go"
)
func main() {
addr := flag.String("addr", "http://localhost:8384", "Syncthing address")
flag.Parse()
w := webview.New(false)
if w == nil {
log.Fatal("failed to create webview")
}
defer w.Destroy()
w.SetTitle("SyncWarden — Admin Panel")
w.SetSize(1024, 768, webview.HintNone)
// Set window icon (title bar + taskbar)
setWindowIcon(w.Window())
w.Navigate(*addr)
w.Run()
}