Re: Spin Progress Indicator is not spinning
Re: Spin Progress Indicator is not spinning
- Subject: Re: Spin Progress Indicator is not spinning
- From: Nathan Kinsinger <email@hidden>
- Date: Thu, 6 Nov 2008 02:32:57 -0700
On Nov 3, 2008, at 7:39 PM, Rashmi Vyshnavi wrote:
Hi all,
I am setting a custom view containing a label and spin style progress
indicator. I want the progress indicator to spin when the menu is
popped up
(similar to AirPort Menu). The progess indicator does not spin
though I call
startAnimation on it. When I change the style to bar the progress
indicator
shows progress. Does any one know how get NSProgressIndicator (Spin
style)
to spin in Menu..
Thanks,
Rashmi
Setup a delegate to the menu and implement menuWillOpen: then use
performSelector:... to start the animation after the current run loop.
It seems to me like the indeterminate progress indicator only accepts
startAnimation: after it's been drawn.
- (void)menuWillOpen:(NSMenu *)menu
{
[progressIndicator performSelector:@selector(startAnimation:)
withObject:self
afterDelay:0.0
inModes:[NSArray arrayWithObject:NSEventTrackingRunLoopMode]];
}
--Nathan
_______________________________________________
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