/* This file is part of Ext JS 3.4 Copyright (c) 2011-2013 Sencha Inc Contact: http://www.sencha.com/contact GNU General Public License Usage This file may be used under the terms of the GNU General Public License version 3.0 as published by the Free Software Foundation and appearing in the file LICENSE included in the packaging of this file. Please review the following information to ensure the GNU General Public License version 3.0 requirements will be met: http://www.gnu.org/copyleft/gpl.html. If you are unsure which license is appropriate for your use, please contact the sales department at http://www.sencha.com/contact. Build date: 2013-04-03 15:07:25 */ Ext.data.JsonP.Ext_Fx({"alternateClassNames":[],"aliases":{},"enum":null,"parentMixins":[],"tagname":"class","subclasses":[],"extends":null,"uses":[],"html":"
Files
A class to provide basic animation and visual effects support. Note: This class is automatically applied\nto the Ext.Element interface when included, so all effects calls should be performed via Ext.Element.\nConversely, since the effects are not actually defined in Ext.Element, Ext.Fx must be\nincluded in order for the Element effects to work.
\n\n\nMethod Chaining
\n\n\nIt is important to note that although the Fx methods and many non-Fx Element methods support \"method chaining\" in that\nthey return the Element object itself as the method return value, it is not always possible to mix the two in a single\nmethod chain. The Fx methods use an internal effects queue so that each effect can be properly timed and sequenced.\nNon-Fx methods, on the other hand, have no such internal queueing and will always execute immediately. For this reason,\nwhile it may be possible to mix certain Fx and non-Fx method calls in a single chain, it may not always provide the\nexpected results and should be done with care. Also see callback.
\n\n\nAnchor Options for Motion Effects
\n\n\nMotion effects support 8-way anchoring, meaning that you can choose one of 8 different anchor points on the Element\nthat will serve as either the start or end point of the animation. Following are all of the supported anchor positions:
\n\n\nValue Description\n----- -----------------------------\ntl The top left corner\nt The center of the top edge\ntr The top right corner\nl The center of the left edge\nr The center of the right edge\nbl The bottom left corner\nb The center of the bottom edge\nbr The bottom right corner\n\n\n\n
Note: some Fx methods accept specific custom config parameters. The options shown in the Config Options\nsection below are common options that can be passed to any Fx method unless otherwise noted.
\nA style specification string, e.g. \"width:100px\", or an object\nin the form {width:\"100px\"}, or a function which returns such a specification that will be applied to the\nElement after the effect finishes.
\nWhether the effect should block other effects from queueing while it runs
\nWhether the effect should block other effects from queueing while it runs
\nA function called when the effect is finished. Note that effects are queued internally by the\nFx class, so a callback is not required to specify another effect -- effects can simply be chained together\nand called in sequence (see note for Method Chaining above), for example:
\n\nel.slideIn().highlight();\n
\n\n\nThe callback is intended for any additional code that should run once a particular effect has completed. The Element\nbeing operated upon is passed as the first parameter.
\nWhether to allow subsequently-queued effects to run at the same time as the current effect, or to ensure that they run in sequence
\nThe length of time (in seconds) that the effect should last
\nThe length of time (in seconds) that the effect should last
\nA valid Ext.lib.Easing value for the effect:
Whether the Element should be removed from the DOM and destroyed after the effect finishes
\nWhether the Element should be removed from the DOM and destroyed after the effect finishes
\nThe scope (this
reference) in which the callback function is executed. Defaults to the browser window.
Whether preceding effects should be stopped and removed before running current effect (only applies to non blocking effects)
\nWhether to use the display CSS property instead of visibility when hiding Elements (only applies to\neffects that end with the element being visually hidden, ignored otherwise)
\nFade an element in (from transparent to opaque). The ending opacity can be specified\nusing the endOpacity config option.\nUsage:
\n\n// default: fade in from opacity 0 to 100%\nel.fadeIn();\n\n// custom: fade in from opacity 0 to 75% over 2 seconds\nel.fadeIn({ endOpacity: .75, duration: 2});\n\n// common config options shown with default values\nel.fadeIn({\n endOpacity: 1, //can be any value between 0 and 1 (e.g. .5)\n easing: 'easeOut',\n duration: .5\n});\n
\n\nObject literal with any of the Fx config options
\nThe Element
\nFade an element out (from opaque to transparent). The ending opacity can be specified\nusing the endOpacity config option. Note that IE may require\nuseDisplay:true in order to redisplay correctly.\nUsage:
\n\n// default: fade out from the element's current opacity to 0\nel.fadeOut();\n\n// custom: fade out from the element's current opacity to 25% over 2 seconds\nel.fadeOut({ endOpacity: .25, duration: 2});\n\n// common config options shown with default values\nel.fadeOut({\n endOpacity: 0, //can be any value between 0 and 1 (e.g. .5)\n easing: 'easeOut',\n duration: .5,\n remove: false,\n useDisplay: false\n});\n
\n\nObject literal with any of the Fx config options
\nThe Element
\nShows a ripple of exploding, attenuating borders to draw attention to an Element.\nUsage:
\n\n// default: a single light blue ripple\nel.frame();\n\n// custom: 3 red ripples lasting 3 seconds total\nel.frame(\"ff0000\", 3, { duration: 3 });\n\n// common config options shown with default values\nel.frame(\"C3DAF9\", 1, {\n duration: 1 //duration of each individual ripple.\n // Note: Easing is not configurable and will be ignored if included\n});\n
\n\nThe color of the border. Should be a 6 char hex color without the leading # (defaults to light blue: 'C3DAF9').
\nThe number of ripples to display (defaults to 1)
\nObject literal with any of the Fx config options
\nThe Element
\nSlides the element while fading it out of view. An anchor point can be optionally passed to set the\nending point of the effect.\nUsage:
\n\n// default: slide the element downward while fading out\nel.ghost();\n\n// custom: slide the element out to the right with a 2-second duration\nel.ghost('r', { duration: 2 });\n\n// common config options shown with default values\nel.ghost('b', {\n easing: 'easeOut',\n duration: .5,\n remove: false,\n useDisplay: false\n});\n
\n\nOne of the valid Fx anchor positions (defaults to bottom: 'b')
\nObject literal with any of the Fx config options
\nThe Element
\nReturns true if the element has any effects actively running or queued, else returns false.
\nTrue if element has active effects, else false
\nReturns true if the element is currently blocking so that no other effect can be queued\nuntil this effect is finished, else returns false if blocking is not set. This is commonly\nused to ensure that an effect initiated by a user action runs to completion prior to the\nsame effect being restarted (e.g., firing only one effect even if the user clicks several times).
\nTrue if blocking, else false
\nHighlights the Element by setting a color (applies to the background-color by default, but can be\nchanged using the \"attr\" config option) and then fading back to the original color. If no original\ncolor is available, you should provide the \"endColor\" config option which will be cleared after the animation.\nUsage:
\n\n// default: highlight background to yellow\nel.highlight();\n\n// custom: highlight foreground text to blue for 2 seconds\nel.highlight(\"0000ff\", { attr: 'color', duration: 2 });\n\n// common config options shown with default values\nel.highlight(\"ffff9c\", {\n attr: \"background-color\", //can be any valid CSS property (attribute) that supports a color value\n endColor: (current color) or \"ffffff\",\n easing: 'easeIn',\n duration: 1\n});\n
\n\nThe highlight color. Should be a 6 char hex color without the leading # (defaults to yellow: 'ffff9c')
\nObject literal with any of the Fx config options
\nThe Element
\nCreates a pause before any subsequent queued effects begin. If there are\nno effects queued after the pause it will have no effect.\nUsage:
\n\nel.pause(1);\n
\n\nThe length of time to pause (in seconds)
\nThe Element
\nFades the element out while slowly expanding it in all directions. When the effect is completed, the\nelement will be hidden (visibility = 'hidden') but block elements will still take up space in the document.\nThe element must be removed from the DOM using the 'remove' config option if desired.\nUsage:
\n\n// default\nel.puff();\n\n// common config options shown with default values\nel.puff({\n easing: 'easeOut',\n duration: .5,\n remove: false,\n useDisplay: false\n});\n
\n\nObject literal with any of the Fx config options
\nThe Element
\nAnimates the transition of an element's dimensions from a starting height/width\nto an ending height/width. This method is a convenience implementation of shift.\nUsage:
\n\n// change height and width to 100x100 pixels\nel.scale(100, 100);\n\n// common config options shown with default values. The height and width will default to\n// the element's existing values if passed as null.\nel.scale(\n [element's width],\n [element's height], {\n easing: 'easeOut',\n duration: .35\n }\n);\n
\n\nThe new width (pass undefined to keep the original width)
\nThe new height (pass undefined to keep the original height)
\nObject literal with any of the Fx config options
\nThe Element
\nEnsures that all effects queued after sequenceFx is called on the element are\nrun in sequence. This is the opposite of syncFx.
\nThe Element
\nAnimates the transition of any combination of an element's dimensions, xy position and/or opacity.\nAny of these properties not specified in the config object will not be changed. This effect\nrequires that at least one new dimension, position or opacity setting must be passed in on\nthe config object in order for the function to have any effect.\nUsage:
\n\n// slide the element horizontally to x position 200 while changing the height and opacity\nel.shift({ x: 200, height: 50, opacity: .8 });\n\n// common config options shown with default values.\nel.shift({\n width: [element's width],\n height: [element's height],\n x: [element's x position],\n y: [element's y position],\n opacity: [element's opacity],\n easing: 'easeOut',\n duration: .35\n});\n
\n\nObject literal with any of the Fx config options
\nThe Element
\nSlides the element into view. An anchor point can be optionally passed to set the point of\norigin for the slide effect. This function automatically handles wrapping the element with\na fixed-size container if needed. See the Fx class overview for valid anchor point options.\nUsage:
\n\n// default: slide the element in from the top\nel.slideIn();\n\n// custom: slide the element in from the right with a 2-second duration\nel.slideIn('r', { duration: 2 });\n\n// common config options shown with default values\nel.slideIn('t', {\n easing: 'easeOut',\n duration: .5\n});\n
\n\nOne of the valid Fx anchor positions (defaults to top: 't')
\nObject literal with any of the Fx config options
\nThe Element
\nSlides the element out of view. An anchor point can be optionally passed to set the end point\nfor the slide effect. When the effect is completed, the element will be hidden (visibility =\n'hidden') but block elements will still take up space in the document. The element must be removed\nfrom the DOM using the 'remove' config option if desired. This function automatically handles\nwrapping the element with a fixed-size container if needed. See the Fx class overview for valid anchor point options.\nUsage:
\n\n// default: slide the element out to the top\nel.slideOut();\n\n// custom: slide the element out to the right with a 2-second duration\nel.slideOut('r', { duration: 2 });\n\n// common config options shown with default values\nel.slideOut('t', {\n easing: 'easeOut',\n duration: .5,\n remove: false,\n useDisplay: false\n});\n
\n\nOne of the valid Fx anchor positions (defaults to top: 't')
\nObject literal with any of the Fx config options
\nThe Element
\nStops any running effects and clears the element's internal effects queue if it contains\nany additional effects that haven't started yet.
\nThe Element
\nBlinks the element as if it was clicked and then collapses on its center (similar to switching off a television).\nWhen the effect is completed, the element will be hidden (visibility = 'hidden') but block elements will still\ntake up space in the document. The element must be removed from the DOM using the 'remove' config option if desired.\nUsage:
\n\n// default\nel.switchOff();\n\n// all config options shown with default values\nel.switchOff({\n easing: 'easeIn',\n duration: .3,\n remove: false,\n useDisplay: false\n});\n
\n\nObject literal with any of the Fx config options
\nThe Element
\nprivate - calls the function taking arguments from the argHash based on the key. Returns the return value of the function.
\n\n this is useful for replacing switch statements (for example).\n
\nEnsures that all effects queued after syncFx is called on the element are\nrun concurrently. This is the opposite of sequenceFx.
\nThe Element
\n