Skip to content

Instantly share code, notes, and snippets.

@erichocean
Created October 3, 2008 21:53
Show Gist options
  • Save erichocean/14659 to your computer and use it in GitHub Desktop.
Save erichocean/14659 to your computer and use it in GitHub Desktop.
isFlashVisible: NO,
_isFlashVisible: NO, // for animation
isFlashVisibleBinding: 'OI.flashController.firstMessage',
isFlashVisibleBindingDefault: SC.Binding.Bool,
isFlashVisibleObserver: function () {
if (this.isFlashVisible != this._isFlashVisible && !this._wrapperAnimation) {
this._wrapperAnimation = Animator.apply( SC.page.get('wrapper').rootElement, "top: 0px;", { duration: 200 });
}
if ( this.isFlashVisible != this._isFlashVisible ) {
this._isFlashVisible = this.isFlashVisible;
this._wrapperAnimation.toggle();
}
}.observes('isFlashVisible')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment