It's the magnifier glass at the top left:
I've tried 2 methods, but both failed.
Once the magnifier glass is clicked, create a new cursor(a cursor with magnifier glass image, or a crossfair, whatever) and push it, then call
nextEventMatchingMask:untilDate:inMode:dequeue:
ofNSApplication
to eat all the events until we get aNSLeftMouseUp
event. It did works but not perfectly, other windows or apps will be ordered front when the click point is out of the origin window.Create a NSColorPanel, try to send a fake mouse click event to the panel. It works on the color wheel, but has no effect once I change the event location to the magnifier glass button.
Question in [1]: How could I forbid all system mouse events dispatching until user clicks the left button?
Question in [2]: Is this possible?
Thanks for any response.