mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
Bug 7931; cleaned up white space in accordance to style guide
This commit is contained in:
parent
0942b3b3f5
commit
135a384cf3
@ -260,11 +260,11 @@ jQuery.fn.extend({
|
|||||||
jQuery.each( ["Left", "Top"], function( i, name ) {
|
jQuery.each( ["Left", "Top"], function( i, name ) {
|
||||||
var method = "scroll" + name;
|
var method = "scroll" + name;
|
||||||
|
|
||||||
jQuery.fn[ method ] = function(val) {
|
jQuery.fn[ method ] = function( val ) {
|
||||||
var elem, win;
|
var elem, win;
|
||||||
|
|
||||||
if(val === undefined) {
|
if( val === undefined ) {
|
||||||
elem = this[0];
|
elem = this[ 0 ];
|
||||||
if( !elem ) {
|
if( !elem ) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
@ -283,10 +283,9 @@ jQuery.each( ["Left", "Top"], function( i, name ) {
|
|||||||
|
|
||||||
if ( win ) {
|
if ( win ) {
|
||||||
win.scrollTo(
|
win.scrollTo(
|
||||||
!i ? val : jQuery(win).scrollLeft(),
|
!i ? val : jQuery( win ).scrollLeft(),
|
||||||
i ? val : jQuery(win).scrollTop()
|
i ? val : jQuery( win ).scrollTop()
|
||||||
);
|
);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
this[ method ] = val;
|
this[ method ] = val;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user