Re: Dismissing menu from menu item that uses custom view
Re: Dismissing menu from menu item that uses custom view
- Subject: Re: Dismissing menu from menu item that uses custom view
- From: Kyle Sluder <email@hidden>
- Date: Thu, 30 May 2013 16:53:03 -0700
On Thu, May 30, 2013, at 06:49 AM, Steve Mills wrote:
> I assume drawing can't get flushed to the screen until control is
> returned to the tracking event loop? What I came up with works, but seems
> ridiculously inelegant. Is there some better way to give the current
> event loop time so I can have the drawing and canceling done right in my
> mouseUp handler?
I would argue that attempting to flush the screen yourself is the far
more inelegant approach. Screen flushing and compositing is handled by
an external process; the system drives repainting, not your app. Yes,
-performSelector:afterDelay: is slightly smelly, but much less so that
trying to force the compositing engine to fake drawing menu selection.
--Kyle Sluder
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden