2

so i have a simple NSMenu. It is attached to a Status Item Button. When i click the Button it pops Open. Now my Problem is that as soon as i click outside of the NSMenu, it closes. How can i avoid that ? I did try many things but cant get that to work.

The reason i need that is that when the user clicks something in the NSMenu, another window opens, and while this window is open i also want the NSMenu to stay open. But it just does not work.

I feel like its impossible.

Many Thanks in advance.

rmaddy
  • 314,917
  • 42
  • 532
  • 579
T1663R
  • 35
  • 5
  • Why do you even _want_ to keep it open? Most people will expect it to close when you click outside; in fact, it's the normal way to close it. – SilverWolf Nov 17 '17 at 20:44

1 Answers1

0

I believe you have to create a custom view that pops up but something that could be done natively with just NSMenu.

nyitguy
  • 598
  • 4
  • 18