Thanks for tip but the menu still closes on mouse up. I wonder what the difference is. The event from [NSApp currentEvent] is showing as a LMouseDown which is good but the menu still takes the mouse up and closes even though you would think it should behave like a normal menu click.
On Oct 29, 2011, at 6:40 AM, Graham Cox wrote: > I have a similar case, and it works OK. > > What I do is on mouseDown, start a timer. When that fires, it grabs [NSApp > currentEvent] and passes that as the event to the popUpContextMenu: method. > The menu tracks as expected. > > The only kink was that because this was being done within a button cell's > tracking, I had to post a fake mouse UP after the menu was closed to ensure > that the cell ended tracking. For a view that may not be necessary unless > you're doing something special on mouse up. > > --Graham Regards, Ryan Joseph thealchemistguild.com _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com