From: Chris Price Date: Mon, 19 Aug 2013 16:12:46 +0000 (+0200) Subject: Fix #14150: revert to ownerDocument.defaultView.getComputedStyle. Close gh-1311.... X-Git-Tag: 1.11.0-beta1~74 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=b414efdd8ea5bd59e2a1b9920abd3a36b06a47f8;p=jquery.git Fix #14150: revert to ownerDocument.defaultView.getComputedStyle. Close gh-1311. (cherry-picked from 3e3680c2cdc524ee9194ef27fdce318cf301144c) --- diff --git a/src/css.js b/src/css.js index 86399aa51..f2c0473dd 100644 --- a/src/css.js +++ b/src/css.js @@ -291,7 +291,7 @@ jQuery.extend({ // because jsdom on node.js will break without it. if ( window.getComputedStyle ) { getStyles = function( elem ) { - return window.getComputedStyle( elem, null ); + return elem.ownerDocument.defaultView.getComputedStyle( elem, null ); }; curCSS = function( elem, name, _computed ) {