• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Smooth Animation
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Smooth Animation


  • Subject: Smooth Animation
  • From: Rhon Fitzwater <email@hidden>
  • Date: Fri, 11 Jun 2004 19:25:07 -0400

Hi,

Right now I have my window so its alpha setting is set to 1.0 when the
mouse enters the window and 0.2 when the mouse exits, using this code:

//mouse entered exited window code below
- (void)viewDidMoveToWindow {
[self addTrackingRect:[self frame] owner:self userData:nil
assumeInside:NO];
[super viewDidMoveToWindow];
}

- (void)mouseEntered:(NSEvent *)event {
NSLog(@"Mouse Entered");
[[self window] setAlphaValue:1.0];

}

- (void)mouseExited:(NSEvent *)event {
NSLog(@"Mouse Exited");
[[self window] setAlphaValue:0.2];
}
//end of mouse entered or exited window code

What I want to know how to do is make the transition between alpha
settings smooth. gradually increase or decrease alpha settings. Can
someone tell me how this can be done, possible with some coding
examples?

Thanks,

-Rhon

[demime 0.98b removed an attachment of type application/pkcs7-signature which had a name of smime.p7s]
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: Smooth Animation
      • From: Daniel Waylonis <email@hidden>
  • Prev by Date: Re: Transparent Images on Buttons in Jaguar?
  • Next by Date: Re: Re-Initializing (clearing) a NSTextView object
  • Previous by thread: Re: Re-Initializing (clearing) a NSTextView object
  • Next by thread: Re: Smooth Animation
  • Index(es):
    • Date
    • Thread