jQuery.fn._height=jQuery.fn.height;jQuery.fn._width=jQuery.fn.width;jQuery.fn.height=function(){if(this[0]==window){return self.innerHeight||jQuery.boxModel&&document.documentElement.clientHeight||document.body.clientHeight}if(this[0]==document){return Math.max(document.body.scrollHeight,document.body.offsetHeight)}return this._height(arguments[0])};jQuery.fn.width=function(){if(this[0]==window){return self.innerWidth||jQuery.boxModel&&document.documentElement.clientWidth||document.body.clientWidth}if(this[0]==document){return Math.max(document.body.scrollWidth,document.body.offsetWidth)}return this._width(arguments[0])};jQuery.fn.innerHeight=function(){return this[0]==window||this[0]==document?this.height():this.css("display")!="none"?this[0].offsetHeight-(parseInt(this.css("borderTopWidth"))||0)-(parseInt(this.css("borderBottomWidth"))||0):this.height()+(parseInt(this.css("paddingTop"))||0)+(parseInt(this.css("paddingBottom"))||0)};jQuery.fn.innerWidth=function(){return this[0]==window||this[0]==document?this.width():this.css("display")!="none"?this[0].offsetWidth-(parseInt(this.css("borderLeftWidth"))||0)-(parseInt(this.css("borderRightWidth"))||0):this.height()+(parseInt(this.css("paddingLeft"))||0)+(parseInt(this.css("paddingRight"))||0)};jQuery.fn.outerHeight=function(){return this[0]==window||this[0]==document?this.height():this.css("display")!="none"?this[0].offsetHeight:this.height()+(parseInt(this.css("borderTopWidth"))||0)+(parseInt(this.css("borderBottomWidth"))||0)+(parseInt(this.css("paddingTop"))||0)+(parseInt(this.css("paddingBottom"))||0)};jQuery.fn.outerWidth=function(){return this[0]==window||this[0]==document?this.width():this.css("display")!="none"?this[0].offsetWidth:this.height()+(parseInt(this.css("borderLeftWidth"))||0)+(parseInt(this.css("borderRightWidth"))||0)+(parseInt(this.css("paddingLeft"))||0)+(parseInt(this.css("paddingRight"))||0)};jQuery.fn.scrollLeft=function(){if(this[0]==window||this[0]==document){return self.pageXOffset||jQuery.boxModel&&document.documentElement.scrollLeft||document.body.scrollLeft}return this[0].scrollLeft};jQuery.fn.scrollTop=function(){if(this[0]==window||this[0]==document){return self.pageYOffset||jQuery.boxModel&&document.documentElement.scrollTop||document.body.scrollTop}return this[0].scrollTop};jQuery.fn.offset=function(L,F){var H=0,G=0,C=this[0],I=this[0],D=0,K=0,L=jQuery.extend({margin:true,border:true,padding:false,scroll:true},L||{});do{H+=I.offsetLeft||0;G+=I.offsetTop||0;if(jQuery.browser.mozilla||jQuery.browser.msie){var J=parseInt(jQuery.css(I,"borderTopWidth"))||0;var B=parseInt(jQuery.css(I,"borderLeftWidth"))||0;H+=B;G+=J;if(jQuery.browser.mozilla&&I!=C&&jQuery.css(I,"overflow")!="visible"){H+=B;G+=J}}var E=I.offsetParent;if(E&&(E.tagName=="BODY"||E.tagName=="HTML")){if((jQuery.browser.safari||jQuery.browser.msie)&&jQuery.css(I,"position")!="absolute"){H+=parseInt(jQuery.css(E,"marginLeft"))||0;G+=parseInt(jQuery.css(E,"marginTop"))||0}break}if(L.scroll){do{D+=I.scrollLeft||0;K+=I.scrollTop||0;I=I.parentNode;if(jQuery.browser.mozilla&&I!=C&&I!=E&&jQuery.css(I,"overflow")!="visible"){G+=parseInt(jQuery.css(I,"borderTopWidth"))||0;H+=parseInt(jQuery.css(I,"borderLeftWidth"))||0}}while(I!=E)}else{I=I.offsetParent}}while(I);if(!L.margin){H-=parseInt(jQuery.css(C,"marginLeft"))||0;G-=parseInt(jQuery.css(C,"marginTop"))||0}if(L.border&&(jQuery.browser.safari||jQuery.browser.opera)){H+=parseInt(jQuery.css(C,"borderLeftWidth"))||0;G+=parseInt(jQuery.css(C,"borderTopWidth"))||0}else{if(!L.border&&!(jQuery.browser.safari||jQuery.browser.opera)){H-=parseInt(jQuery.css(C,"borderLeftWidth"))||0;G-=parseInt(jQuery.css(C,"borderTopWidth"))||0}}if(L.padding){H+=parseInt(jQuery.css(C,"paddingLeft"))||0;G+=parseInt(jQuery.css(C,"paddingTop"))||0}if(L.scroll&&jQuery.browser.opera&&jQuery.css(C,"display")=="inline"){D-=C.scrollLeft||0;K-=C.scrollTop||0}var A=L.scroll?{top:G-K,left:H-D,scrollTop:K,scrollLeft:D}:{top:G,left:H};if(F){jQuery.extend(F,A);return this}else{return A}}