MCPcopy Create free account
hub / github.com/JsAaron/jQuery / propFilter

Function propFilter

2.1.1/test/jquery-1.11.1.js:7247–7282  ·  view source on GitHub ↗
( props, specialEasing )

Source from the content-addressed store, hash-verified

7245}
7246
7247function propFilter( props, specialEasing ) {
7248 var index, name, easing, value, hooks;
7249
7250 // camelCase, specialEasing and expand cssHook pass
7251 for ( index in props ) {
7252 name = jQuery.camelCase( index );
7253 easing = specialEasing[ name ];
7254 value = props[ index ];
7255 if ( jQuery.isArray( value ) ) {
7256 easing = value[ 1 ];
7257 value = props[ index ] = value[ 0 ];
7258 }
7259
7260 if ( index !== name ) {
7261 props[ name ] = value;
7262 delete props[ index ];
7263 }
7264
7265 hooks = jQuery.cssHooks[ name ];
7266 if ( hooks && "expand" in hooks ) {
7267 value = hooks.expand( value );
7268 delete props[ name ];
7269
7270 // not quite $.extend, this wont overwrite keys already present.
7271 // also - reusing 'index' from above because we have the correct "name"
7272 for ( index in value ) {
7273 if ( !( index in props ) ) {
7274 props[ index ] = value[ index ];
7275 specialEasing[ index ] = easing;
7276 }
7277 }
7278 } else {
7279 specialEasing[ name ] = easing;
7280 }
7281 }
7282}
7283
7284function Animation( elem, properties, options ) {
7285 var result,

Callers 1

AnimationFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected