vendor/assets/javascripts/jquery.js in jquery-cdn-2.2.3 vs vendor/assets/javascripts/jquery.js in jquery-cdn-2.2.4
- old
+ new
@@ -1,17 +1,17 @@
/*!
- * jQuery JavaScript Library v2.2.3
+ * jQuery JavaScript Library v2.2.4
* http://jquery.com/
*
* Includes Sizzle.js
* http://sizzlejs.com/
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license
* http://jquery.org/license
*
- * Date: 2016-04-05T19:26Z
+ * Date: 2016-05-20T17:23Z
*/
(function( global, factory ) {
if ( typeof module === "object" && typeof module.exports === "object" ) {
@@ -63,11 +63,11 @@
var support = {};
var
- version = "2.2.3",
+ version = "2.2.4",
// Define a local copy of jQuery
jQuery = function( selector, context ) {
// The jQuery object is actually just the init constructor 'enhanced'
@@ -5004,35 +5004,36 @@
jQuery.Event.prototype = {
constructor: jQuery.Event,
isDefaultPrevented: returnFalse,
isPropagationStopped: returnFalse,
isImmediatePropagationStopped: returnFalse,
+ isSimulated: false,
preventDefault: function() {
var e = this.originalEvent;
this.isDefaultPrevented = returnTrue;
- if ( e ) {
+ if ( e && !this.isSimulated ) {
e.preventDefault();
}
},
stopPropagation: function() {
var e = this.originalEvent;
this.isPropagationStopped = returnTrue;
- if ( e ) {
+ if ( e && !this.isSimulated ) {
e.stopPropagation();
}
},
stopImmediatePropagation: function() {
var e = this.originalEvent;
this.isImmediatePropagationStopped = returnTrue;
- if ( e ) {
+ if ( e && !this.isSimulated ) {
e.stopImmediatePropagation();
}
this.stopPropagation();
}
@@ -5959,23 +5960,10 @@
var valueIsBorderBox = true,
val = name === "width" ? elem.offsetWidth : elem.offsetHeight,
styles = getStyles( elem ),
isBorderBox = jQuery.css( elem, "boxSizing", false, styles ) === "border-box";
- // Support: IE11 only
- // In IE 11 fullscreen elements inside of an iframe have
- // 100x too small dimensions (gh-1764).
- if ( document.msFullscreenElement && window.top !== window ) {
-
- // Support: IE11 only
- // Running getBoundingClientRect on a disconnected node
- // in IE throws an error.
- if ( elem.getClientRects().length ) {
- val = Math.round( elem.getBoundingClientRect()[ name ] * 100 );
- }
- }
-
// Some non-html elements return undefined for offsetWidth, so check for null/undefined
// svg - https://bugzilla.mozilla.org/show_bug.cgi?id=649285
// MathML - https://bugzilla.mozilla.org/show_bug.cgi?id=491668
if ( val <= 0 || val == null ) {
@@ -7862,37 +7850,21 @@
return event.result;
},
// Piggyback on a donor event to simulate a different one
+ // Used only for `focus(in | out)` events
simulate: function( type, elem, event ) {
var e = jQuery.extend(
new jQuery.Event(),
event,
{
type: type,
isSimulated: true
-
- // Previously, `originalEvent: {}` was set here, so stopPropagation call
- // would not be triggered on donor event, since in our own
- // jQuery.event.stopPropagation function we had a check for existence of
- // originalEvent.stopPropagation method, so, consequently it would be a noop.
- //
- // But now, this "simulate" function is used only for events
- // for which stopPropagation() is noop, so there is no need for that anymore.
- //
- // For the 1.x branch though, guard for "click" and "submit"
- // events is still used, but was moved to jQuery.event.stopPropagation function
- // because `originalEvent` should point to the original event for the constancy
- // with other events and for more focused logic
}
);
jQuery.event.trigger( e, null, elem );
-
- if ( e.isDefaultPrevented() ) {
- event.preventDefault();
- }
}
} );
jQuery.fn.extend( {