Open Bug 468340 Opened 13 years ago Updated 13 years ago

Add fade in animation to Tabspose


(Camino Graveyard :: Tabbed Browsing, defect)

Not set


(Not tracked)


(Reporter: Jeff.Dlouhy, Assigned: Jeff.Dlouhy)



(1 file)

Tabsposé needs more cowbell. While there are some cool things I would like to do with Core Animation, just to get off the ground we need some basic animations for when new tabs are coming in.

Right now when a thumbnail it is finished loading, it immediately gets drawn to the grid. My first quick idea is to have the tabs fade in once they load. Before we're done here.. Tabsposé will be wearing gold-plated diapers.
Attached patch FadeIn V1Splinter Review
Initial patch.
Hardware: PC → All
Comment on attachment 351798 [details] [diff] [review]
FadeIn V1

Probably should have someone look at this.
Attachment #351798 - Flags: review?(murph)
Attachment #351798 - Flags: review?(murph) → review-
Comment on attachment 351798 [details] [diff] [review]
FadeIn V1

>+  NSViewAnimation* mFadeAnimation;


>+  mFadeAnimation = [[[NSViewAnimation alloc] initWithViewAnimations:[NSArray arrayWithObject:viewDict]] autorelease];

You declare mFadeAnimation as an instance variable, but then autorelease the object leaving a dangling pointer available for reference throughout the class.  I don't see any reason the animation needs to be an instance variable, we do not call anything on it outside of this method.  If you later include a method that will reference it, you'll need to, instead of autoreleasing it, retain it and then relese and nil it in the animation did end and stop delegate methods.


Also, behavior wise, the fade in animations seem to have a problem flickering and the opacity jumping around.  I am fairly confident that this is due to a bug in NSViewAnimation (which is why I actually wrote my own class to slide views around).  When using NSAnimationNonblockingThreaded, NSViewAnimation does not perform updated drawing on the main thread, and drawing from a secondary thread often presents itself with white flickering.  We'll have to file this rdar.  To test, open the "shopping" bookmarks in tabs and display and overview of them, that's one example that seems to do it here.

r- for now, not just because of the instance variable, but see if there is anything you can do about the flickering problem.  If not, even with an occasional flickering, I feel the fade ins still are a definite improvement!
You need to log in before you can comment on or make changes to this bug.