Yahoo! UI Library

Container  2.6.0

Yahoo! UI Library > container > YAHOO.widget.ContainerEffect

Class YAHOO.widget.ContainerEffect

ContainerEffect encapsulates animation transitions that are executed when an Overlay is shown or hidden.

Constructor

YAHOO.widget.ContainerEffect ( overlay , attrIn , attrOut , targetElement , Optional. )
Parameters:
overlay <YAHOO.widget.Overlay> The Overlay that the animation should be associated with
attrIn <Object> The object literal representing the animation arguments to be used for the animate-in transition. The arguments for this literal are: attributes(object, see YAHOO.util.Anim for description), duration(Number), and method(i.e. Easing.easeIn).
attrOut <Object> The object literal representing the animation arguments to be used for the animate-out transition. The arguments for this literal are: attributes(object, see YAHOO.util.Anim for description), duration(Number), and method(i.e. Easing.easeIn).
targetElement <HTMLElement> Optional. The target element that should be animated during the transition. Defaults to overlay.element.
Optional. <class> The animation class to instantiate. Defaults to YAHOO.util.Anim. Other options include YAHOO.util.Motion.

Properties

animClass - class

The animation class to use for animating the overlay

attrIn - Object

The animation attributes to use when transitioning into view

attrOut - Object

The animation attributes to use when transitioning out of view

overlay - YAHOO.widget.Overlay

The overlay to animate

targetElement - HTMLElement

The target element to be animated

Methods

animateIn

void animateIn ( )
Triggers the in-animation.
Returns: void

animateOut

void animateOut ( )
Triggers the out-animation.
Returns: void

FADE

static YAHOO.widget.ContainerEffect FADE ( overlay , dur )
A pre-configured ContainerEffect instance that can be used for fading an overlay in and out.
Parameters:
overlay <YAHOO.widget.Overlay> The Overlay object to animate
dur <Number> The duration of the animation
Returns: YAHOO.widget.ContainerEffect
The configured ContainerEffect object

handleCompleteAnimateIn

void handleCompleteAnimateIn ( type , args , obj )
The default onComplete handler for the in-animation.
Parameters:
type <String> The CustomEvent type
args <Object[]> The CustomEvent arguments
obj <Object> The scope object
Returns: void

handleCompleteAnimateOut

void handleCompleteAnimateOut ( type , args , obj )
The default onComplete handler for the out-animation.
Parameters:
type <String> The CustomEvent type
args <Object[]> The CustomEvent arguments
obj <Object> The scope object
Returns: void

handleStartAnimateIn

void handleStartAnimateIn ( type , args , obj )
The default onStart handler for the in-animation.
Parameters:
type <String> The CustomEvent type
args <Object[]> The CustomEvent arguments
obj <Object> The scope object
Returns: void

handleStartAnimateOut

void handleStartAnimateOut ( type , args , obj )
The default onStart handler for the out-animation.
Parameters:
type <String> The CustomEvent type
args <Object[]> The CustomEvent arguments
obj <Object> The scope object
Returns: void

handleTweenAnimateIn

void handleTweenAnimateIn ( type , args , obj )
The default onTween handler for the in-animation.
Parameters:
type <String> The CustomEvent type
args <Object[]> The CustomEvent arguments
obj <Object> The scope object
Returns: void

handleTweenAnimateOut

void handleTweenAnimateOut ( type , args , obj )
The default onTween handler for the out-animation.
Parameters:
type <String> The CustomEvent type
args <Object[]> The CustomEvent arguments
obj <Object> The scope object
Returns: void

init

void init ( )
Initializes the animation classes and events.
Returns: void

SLIDE

static YAHOO.widget.ContainerEffect SLIDE ( overlay , dur )
A pre-configured ContainerEffect instance that can be used for sliding an overlay in and out.
Parameters:
overlay <YAHOO.widget.Overlay> The Overlay object to animate
dur <Number> The duration of the animation
Returns: YAHOO.widget.ContainerEffect
The configured ContainerEffect object

toString

String toString ( )
Returns a string representation of the object.
Returns: String
The string representation of the ContainerEffect


Copyright © 2008 Yahoo! Inc. All rights reserved.