Merge "Make MWHttpRequest::__construct() protected."
[lhc/web/wiklou.git] / resources / jquery.ui / jquery.ui.core.js
index 2a8a2c1..40211cc 100644 (file)
@@ -1,5 +1,5 @@
 /*!
- * jQuery UI 1.8.21
+ * jQuery UI 1.8.22
  *
  * Copyright 2012, AUTHORS.txt (http://jqueryui.com/about)
  * Dual licensed under the MIT or GPL Version 2 licenses.
@@ -18,7 +18,7 @@ if ( $.ui.version ) {
 }
 
 $.extend( $.ui, {
-       version: "1.8.21",
+       version: "1.8.22",
 
        keyCode: {
                ALT: 18,
@@ -131,49 +131,52 @@ $.fn.extend({
        }
 });
 
-$.each( [ "Width", "Height" ], function( i, name ) {
-       var side = name === "Width" ? [ "Left", "Right" ] : [ "Top", "Bottom" ],
-               type = name.toLowerCase(),
-               orig = {
-                       innerWidth: $.fn.innerWidth,
-                       innerHeight: $.fn.innerHeight,
-                       outerWidth: $.fn.outerWidth,
-                       outerHeight: $.fn.outerHeight
-               };
+// support: jQuery <1.8
+if ( !$( "<a>" ).outerWidth( 1 ).jquery ) {
+       $.each( [ "Width", "Height" ], function( i, name ) {
+               var side = name === "Width" ? [ "Left", "Right" ] : [ "Top", "Bottom" ],
+                       type = name.toLowerCase(),
+                       orig = {
+                               innerWidth: $.fn.innerWidth,
+                               innerHeight: $.fn.innerHeight,
+                               outerWidth: $.fn.outerWidth,
+                               outerHeight: $.fn.outerHeight
+                       };
+
+               function reduce( elem, size, border, margin ) {
+                       $.each( side, function() {
+                               size -= parseFloat( $.curCSS( elem, "padding" + this, true) ) || 0;
+                               if ( border ) {
+                                       size -= parseFloat( $.curCSS( elem, "border" + this + "Width", true) ) || 0;
+                               }
+                               if ( margin ) {
+                                       size -= parseFloat( $.curCSS( elem, "margin" + this, true) ) || 0;
+                               }
+                       });
+                       return size;
+               }
 
-       function reduce( elem, size, border, margin ) {
-               $.each( side, function() {
-                       size -= parseFloat( $.curCSS( elem, "padding" + this, true) ) || 0;
-                       if ( border ) {
-                               size -= parseFloat( $.curCSS( elem, "border" + this + "Width", true) ) || 0;
-                       }
-                       if ( margin ) {
-                               size -= parseFloat( $.curCSS( elem, "margin" + this, true) ) || 0;
+               $.fn[ "inner" + name ] = function( size ) {
+                       if ( size === undefined ) {
+                               return orig[ "inner" + name ].call( this );
                        }
-               });
-               return size;
-       }
-
-       $.fn[ "inner" + name ] = function( size ) {
-               if ( size === undefined ) {
-                       return orig[ "inner" + name ].call( this );
-               }
 
-               return this.each(function() {
-                       $( this ).css( type, reduce( this, size ) + "px" );
-               });
-       };
+                       return this.each(function() {
+                               $( this ).css( type, reduce( this, size ) + "px" );
+                       });
+               };
 
-       $.fn[ "outer" + name] = function( size, margin ) {
-               if ( typeof size !== "number" ) {
-                       return orig[ "outer" + name ].call( this, size );
-               }
+               $.fn[ "outer" + name] = function( size, margin ) {
+                       if ( typeof size !== "number" ) {
+                               return orig[ "outer" + name ].call( this, size );
+                       }
 
-               return this.each(function() {
-                       $( this).css( type, reduce( this, size, true, margin ) + "px" );
-               });
-       };
-});
+                       return this.each(function() {
+                               $( this).css( type, reduce( this, size, true, margin ) + "px" );
+                       });
+               };
+       });
+}
 
 // selectors
 function focusable( element, isTabIndexNotNaN ) {
@@ -205,9 +208,16 @@ function visible( element ) {
 }
 
 $.extend( $.expr[ ":" ], {
-       data: function( elem, i, match ) {
-               return !!$.data( elem, match[ 3 ] );
-       },
+       data: $.expr.createPseudo ?
+               $.expr.createPseudo(function( dataName ) {
+                       return function( elem ) {
+                               return !!$.data( elem, dataName );
+                       };
+               }) :
+               // support: jQuery <1.8
+               function( elem, i, match ) {
+                       return !!$.data( elem, match[ 3 ] );
+               },
 
        focusable: function( element ) {
                return focusable( element, !isNaN( $.attr( element, "tabindex" ) ) );
@@ -245,6 +255,11 @@ $(function() {
        body.removeChild( div ).style.display = "none";
 });
 
+// jQuery <1.4.3 uses curCSS, in 1.4.3 - 1.7.2 curCSS = css, 1.8+ only has css
+if ( !$.curCSS ) {
+       $.curCSS = $.css;
+}
+