| 9228 | |
| 9229 | // Generate parameters to create a standard animation |
| 9230 | function genFx( type, includeWidth ) { |
| 9231 | var which, |
| 9232 | attrs = { height: type }, |
| 9233 | i = 0; |
| 9234 | |
| 9235 | // if we include width, step value is 1 to do all cssExpand values, |
| 9236 | // if we don't include width, step value is 2 to skip over Left and Right |
| 9237 | includeWidth = includeWidth? 1 : 0; |
| 9238 | for( ; i < 4 ; i += 2 - includeWidth ) { |
| 9239 | which = cssExpand[ i ]; |
| 9240 | attrs[ "margin" + which ] = attrs[ "padding" + which ] = type; |
| 9241 | } |
| 9242 | |
| 9243 | if ( includeWidth ) { |
| 9244 | attrs.opacity = attrs.width = type; |
| 9245 | } |
| 9246 | |
| 9247 | return attrs; |
| 9248 | } |
| 9249 | |
| 9250 | // Generate shortcuts for custom animations |
| 9251 | jQuery.each({ |