From 5d9bc4ca81ef2cef78744c660ee2700c354dfebb Mon Sep 17 00:00:00 2001 From: Lea Anthony Date: Wed, 5 Jul 2023 21:09:48 +1000 Subject: [PATCH] [v3 mac] Fix systray example toggle --- v3/examples/systray/main.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/v3/examples/systray/main.go b/v3/examples/systray/main.go index 26cf0431..52bb01ec 100644 --- a/v3/examples/systray/main.go +++ b/v3/examples/systray/main.go @@ -83,7 +83,11 @@ func main() { } showWindow := func() { - if justClosed { + if runtime.GOOS == "windows" && justClosed { + return + } + if window.IsVisible() { + window.Hide() return } _ = systemTray.PositionWindow(window, 5)