aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJohn Resig <jeresig@gmail.com>2011-01-20 14:39:57 -0500
committerJohn Resig <jeresig@gmail.com>2011-01-20 14:39:57 -0500
commitc97b6ee36a1402b6f4bb3f6893b687eb294c41df (patch)
tree3b5594171139e68cbcd0547ec352b6c3dd60b964 /src
parent35875acd03cc95eace495f887511f2b61f223f7a (diff)
parent2b64b1db6877f52ea2958c6aafb0e4644fbcfe13 (diff)
downloadjquery-c97b6ee36a1402b6f4bb3f6893b687eb294c41df.tar.gz
jquery-c97b6ee36a1402b6f4bb3f6893b687eb294c41df.zip
Merge branch 'master' of https://github.com/scottjehl/jquery into scottjehl-master
Diffstat (limited to 'src')
-rw-r--r--src/dimensions.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/dimensions.js b/src/dimensions.js
index 17b4f8f96..e2d411dd2 100644
--- a/src/dimensions.js
+++ b/src/dimensions.js
@@ -35,8 +35,10 @@ jQuery.each([ "Height", "Width" ], function( i, name ) {
if ( jQuery.isWindow( elem ) ) {
// Everyone else use document.documentElement or document.body depending on Quirks vs Standards mode
- return elem.document.compatMode === "CSS1Compat" && elem.document.documentElement[ "client" + name ] ||
- elem.document.body[ "client" + name ];
+ // 3rd condition allows Nokia support, as it supports the docElem prop but not CSS1Compat
+ var docElemProp = elem.document.documentElement[ "client" + name ];
+ return elem.document.compatMode === "CSS1Compat" && docElemProp ||
+ elem.document.body[ "client" + name ] || docElemProp;
// Get document width or height
} else if ( elem.nodeType === 9 ) {