(elem, props, opts)
| 257 | }); |
| 258 | |
| 259 | function defaultPrefilter(elem, props, opts) { |
| 260 | /* jshint validthis: true */ |
| 261 | var prop, value, toggle, tween, hooks, oldfire, |
| 262 | anim = this, |
| 263 | orig = {}, |
| 264 | style = elem.style, |
| 265 | hidden = elem.nodeType && isHidden(elem), |
| 266 | dataShow = data_priv.get(elem, "fxshow"); |
| 267 | |
| 268 | // handle queue: false promises |
| 269 | if (!opts.queue) { |
| 270 | hooks = jQuery._queueHooks(elem, "fx"); |
| 271 | if (hooks.unqueued == null) { |
| 272 | hooks.unqueued = 0; |
| 273 | oldfire = hooks.empty.fire; |
| 274 | hooks.empty.fire = function() { |
| 275 | if (!hooks.unqueued) { |
| 276 | oldfire(); |
| 277 | } |
| 278 | }; |
| 279 | } |
| 280 | hooks.unqueued++; |
| 281 | |
| 282 | anim.always(function() { |
| 283 | // doing this makes sure that the complete handler will be called |
| 284 | // before this completes |
| 285 | anim.always(function() { |
| 286 | hooks.unqueued--; |
| 287 | if (!jQuery.queue(elem, "fx").length) { |
| 288 | hooks.empty.fire(); |
| 289 | } |
| 290 | }); |
| 291 | }); |
| 292 | } |
| 293 | |
| 294 | // height/width overflow pass |
| 295 | if (elem.nodeType === 1 && ("height" in props || "width" in props)) { |
| 296 | // Make sure that nothing sneaks out |
| 297 | // Record all 3 overflow attributes because IE9-10 do not |
| 298 | // change the overflow attribute when overflowX and |
| 299 | // overflowY are set to the same value |
| 300 | opts.overflow = [style.overflow, style.overflowX, style.overflowY]; |
| 301 | |
| 302 | // Set display property to inline-block for height/width |
| 303 | // animations on inline elements that are having width/height animated |
| 304 | if (jQuery.css(elem, "display") === "inline" && |
| 305 | jQuery.css(elem, "float") === "none") { |
| 306 | |
| 307 | style.display = "inline-block"; |
| 308 | } |
| 309 | } |
| 310 | |
| 311 | if (opts.overflow) { |
| 312 | style.overflow = "hidden"; |
| 313 | anim.always(function() { |
| 314 | style.overflow = opts.overflow[0]; |
| 315 | style.overflowX = opts.overflow[1]; |
| 316 | style.overflowY = opts.overflow[2]; |
nothing calls this directly
no test coverage detected