mirror of
https://github.com/netbirdio/systray.git
synced 2026-05-22 17:08:41 -07:00
Create menu before calling onReady on Windows
This commit is contained in:
committed by
Seth Wright
parent
e849b2a1b8
commit
229901a943
+1
-3
@@ -253,11 +253,8 @@ func (t *winTray) wndProc(hWnd windows.Handle, message uint32, wParam, lParam ui
|
||||
WM_ENDSESSION = 0x0016
|
||||
WM_CLOSE = 0x0010
|
||||
WM_DESTROY = 0x0002
|
||||
WM_CREATE = 0x0001
|
||||
)
|
||||
switch message {
|
||||
case WM_CREATE:
|
||||
systrayReady()
|
||||
case WM_COMMAND:
|
||||
menuItemId := int32(wParam)
|
||||
// https://docs.microsoft.com/en-us/windows/win32/menurc/wm-command#menus
|
||||
@@ -778,6 +775,7 @@ func registerSystray() {
|
||||
return
|
||||
}
|
||||
|
||||
systrayReady()
|
||||
}
|
||||
|
||||
func nativeLoop() {
|
||||
|
||||
Reference in New Issue
Block a user