aboutsummaryrefslogtreecommitdiffstats
path: root/src/dimensions.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/dimensions.js')
-rw-r--r--src/dimensions.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/dimensions.js b/src/dimensions.js
index 30b55fbc0..c5f49ac09 100644
--- a/src/dimensions.js
+++ b/src/dimensions.js
@@ -19,10 +19,10 @@ jQuery.each( { Height: "height", Width: "width" }, function( name, type ) {
if ( jQuery.isWindow( elem ) ) {
- // As of 5/8/2012 this will yield incorrect results for Mobile Safari, but there
- // isn't a whole lot we can do. See pull request at this URL for discussion:
- // https://github.com/jquery/jquery/pull/764
- return elem.document.documentElement[ "client" + name ];
+ // $( window ).outerWidth/Height return w/h including scrollbars (gh-1729)
+ return funcName.indexOf( "outer" ) === 0 ?
+ elem[ "inner" + name ] :
+ elem.document.documentElement[ "client" + name ];
}
// Get document width or height