Package: | Ext |
Defined In: | Fx.js |
Class: | Fx |
Extends: | Object |
A class to provide basic animation and visual effects support. Note: This class is automatically applied to the Ext.Element interface when included, so all effects calls should be performed via Element. Conversely, since the effects are not actually defined in Element, Ext.Fx must be included in order for the Element effects to work.
It is important to note that although the Fx methods and many non-Fx Element methods support "method chaining" in that they return the Element object itself as the method return value, it is not always possible to mix the two in a single method chain. The Fx methods use an internal effects queue so that each effect can be properly timed and sequenced. Non-Fx methods, on the other hand, have no such internal queueing and will always execute immediately. For this reason, while it may be possible to mix certain Fx and non-Fx method calls in a single chain, it may not always provide the expected results and should be done with care.
Motion effects support 8-way anchoring, meaning that you can choose one of 8 different anchor points on the Element that will serve as either the start or end point of the animation. Following are all of the supported anchor positions:
Value Description ----- ----------------------------- tl The top left corner t The center of the top edge tr The top right corner l The center of the left edge r The center of the right edge bl The bottom left corner b The center of the bottom edge br The bottom right cornerAlthough some Fx methods accept specific custom config parameters, the ones shown in the Config Options section below are common options that can be passed to any Fx method.
Method | Defined By | |
---|---|---|
fadeIn( [Object options ] ) : Ext.Element Fade an element in (from transparent to opaque). The ending opacity can be specified
using the "endOpacity" config o...
Fade an element in (from transparent to opaque). The ending opacity can be specified
using the "endOpacity" config option.
Usage:
Parameters:
|
Fx | |
fadeOut( [Object options ] ) : Ext.Element Fade an element out (from opaque to transparent). The ending opacity can be specified
using the "endOpacity" config ...
Fade an element out (from opaque to transparent). The ending opacity can be specified
using the "endOpacity" config option. Note that IE may require useDisplay:true in order
to redisplay correctly.
Usage:
Parameters:
|
Fx | |
frame( [String color ], [Number count ], [Object options ] ) : Ext.Element Shows a ripple of exploding, attenuating borders to draw attention to an Element.
Usage:
// default: a single light ...
Shows a ripple of exploding, attenuating borders to draw attention to an Element.
Usage:
Parameters:
|
Fx | |
ghost( [String anchor ], [Object options ] ) : Ext.Element Slides the element while fading it out of view. An anchor point can be optionally passed to set the
ending point of...
Slides the element while fading it out of view. An anchor point can be optionally passed to set the
ending point of the effect.
Usage:
Parameters:
|
Fx | |
hasActiveFx() : Boolean Returns true if the element has any effects actively running or queued, else returns false.
Returns true if the element has any effects actively running or queued, else returns false.
Parameters:
|
Fx | |
hasFxBlock() : Boolean Returns true if the element is currently blocking so that no other effect can be queued
until this effect is finished...
Returns true if the element is currently blocking so that no other effect can be queued
until this effect is finished, else returns false if blocking is not set. This is commonly
used to ensure that an effect initiated by a user action runs to completion prior to the
same effect being restarted (e.g., firing only one effect even if the user clicks several times).
Parameters:
|
Fx | |
highlight( [String color ], [Object options ] ) : Ext.Element Highlights the Element by setting a color (applies to the background-color by default, but can be
changed using the "...
Highlights the Element by setting a color (applies to the background-color by default, but can be
changed using the "attr" config option) and then fading back to the original color. If no original
color is available, you should provide the "endColor" config option which will be cleared after the animation.
Usage:
Parameters:
|
Fx | |
pause( Number seconds ) : Ext.Element Creates a pause before any subsequent queued effects begin. If there are
no effects queued after the pause it will h...
Creates a pause before any subsequent queued effects begin. If there are
no effects queued after the pause it will have no effect.
Usage:
Parameters:
|
Fx | |
puff( [Object options ] ) : Ext.Element Fades the element out while slowly expanding it in all directions. When the effect is completed, the
element will b...
Fades the element out while slowly expanding it in all directions. When the effect is completed, the
element will be hidden (visibility = 'hidden') but block elements will still take up space in the document.
The element must be removed from the DOM using the 'remove' config option if desired.
Usage:
Parameters:
|
Fx | |
scale( Number width , Number height , [Object options ] ) : Ext.Element Animates the transition of an element's dimensions from a starting height/width
to an ending height/width.
Usage:
//...
Animates the transition of an element's dimensions from a starting height/width
to an ending height/width.
Usage:
Parameters:
|
Fx | |
sequenceFx() : Ext.Element Ensures that all effects queued after sequenceFx is called on the element are
run in sequence. This is the opposite ...
Ensures that all effects queued after sequenceFx is called on the element are
run in sequence. This is the opposite of syncFx.
Parameters:
|
Fx | |
shift( Object options ) : Ext.Element Animates the transition of any combination of an element's dimensions, xy position and/or opacity.
Any of these prope...
Animates the transition of any combination of an element's dimensions, xy position and/or opacity.
Any of these properties not specified in the config object will not be changed. This effect
requires that at least one new dimension, position or opacity setting must be passed in on
the config object in order for the function to have any effect.
Usage:
Parameters:
|
Fx | |
slideIn( [String anchor ], [Object options ] ) : Ext.Element Slides the element into view. An anchor point can be optionally passed to set the point of
origin for the slide effe...
Slides the element into view. An anchor point can be optionally passed to set the point of
origin for the slide effect. This function automatically handles wrapping the element with
a fixed-size container if needed. See the Fx class overview for valid anchor point options.
Usage:
Parameters:
|
Fx | |
slideOut( [String anchor ], [Object options ] ) : Ext.Element Slides the element out of view. An anchor point can be optionally passed to set the end point
for the slide effect. ...
Slides the element out of view. An anchor point can be optionally passed to set the end point
for the slide effect. When the effect is completed, the element will be hidden (visibility =
'hidden') but block elements will still take up space in the document. The element must be removed
from the DOM using the 'remove' config option if desired. This function automatically handles
wrapping the element with a fixed-size container if needed. See the Fx class overview for valid anchor point options.
Usage:
Parameters:
|
Fx | |
stopFx() : Ext.Element Stops any running effects and clears the element's internal effects queue if it contains
any additional effects that ...
Stops any running effects and clears the element's internal effects queue if it contains
any additional effects that haven't started yet.
Parameters:
|
Fx | |
switchOff( [Object options ] ) : Ext.Element Blinks the element as if it was clicked and then collapses on its center (similar to switching off a television).
Whe...
Blinks the element as if it was clicked and then collapses on its center (similar to switching off a television).
When the effect is completed, the element will be hidden (visibility = 'hidden') but block elements will still
take up space in the document. The element must be removed from the DOM using the 'remove' config option if desired.
Usage:
Parameters:
|
Fx | |
syncFx() : Ext.Element Ensures that all effects queued after syncFx is called on the element are
run concurrently. This is the opposite of ...
Ensures that all effects queued after syncFx is called on the element are
run concurrently. This is the opposite of sequenceFx.
Parameters:
|
Fx |