[Windows] Menu stays open after users click off it
Currently, after opening a menu -- if the menu is not inside the app window -- the menu will stay open until it is interacted with.
The platform native behaviour would be to close the menu if the users clicks somewhere that is not the menu.
It seems that I've been running into this. When adding SetForegroundWindow and PostMessage this misbehavior is resolved.
Unfortunately, as a consequence, the entire app window is send into foreground when doing so. There has to be a way to achieve this without running into this, as native and electron apps are able to do it just fine.
Maybe we can listen to the mouse click event and hide it after the mouse click