On 6/4/08 2:25 AM, Brian Christensen said: >The window's frame is an animatable property, so you could try >something like this: > >- (void)showWindow:(id)window >{ > NSRect startFrom = NSZeroRect; > NSRect endAt = [window frame]; > CGFloat duration = 5.0; > > [window setFrame:startFrom display:NO]; > [window orderFrontAndMakeKey:nil]; > > [NSAnimationContext beginGrouping]; > [[NSAnimationContext currentContext] setDuration:duration]; > > [[window animator] setFrame:endAt display:YES]; > > [NSAnimationContext endGrouping]; >}
That'll work, but in my experience if any of the controls in the window make use of 'autoresizing springs' then they will resize incorrectly if starting from a window size smaller that the control's minimum size. -- ____________________________________________________________ Sean McBride, B. Eng [EMAIL PROTECTED] Rogue Research www.rogue-research.com Mac Software Developer Montréal, Québec, Canada _______________________________________________ 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 [EMAIL PROTECTED]