托盘菜单失去焦点自动消失 困扰了一周的问题竟然是这个原因: 在 TrackPopoMenu 调用之前调用 SetForegroundWindow 。 参考:http://www.slyar.com/blog/tray-menu-exit.html