]> source.dussan.org Git - jquery-ui.git/commitdiff
Effect core: Making animate class cross-frame safe, style guidence
authorCorey Frang <gnarf@gnarf.net>
Thu, 29 Sep 2011 22:55:58 +0000 (18:55 -0400)
committerCorey Frang <gnarf@gnarf.net>
Thu, 29 Sep 2011 22:55:58 +0000 (18:55 -0400)
ui/jquery.effects.core.js

index 15d81b4b0d33273ad53940f010f8a2c7fb6bd833..699b41d818272c7baca47c27fe972fc75eb203cf 100644 (file)
@@ -161,7 +161,7 @@ var classAnimationActions = [ "add", "remove", "toggle" ],
        // prefix used for storing data on .data()
        dataSpace = "ec.storage.";
 
-$.each([ "borderLeftStyle", "borderRightStyle", "borderBottomStyle", "borderTopStyle" ], function(_, prop) {
+$.each([ "borderLeftStyle", "borderRightStyle", "borderBottomStyle", "borderTopStyle" ], function( _, prop ) {
        $.fx.step[ prop ] = function( fx ) {
                if ( fx.end !== "none" && !fx.setAttr || fx.pos === 1 && !fx.setAttr ) {
                        jQuery.style( fx.elem, prop, fx.end );
@@ -171,8 +171,8 @@ $.each([ "borderLeftStyle", "borderRightStyle", "borderBottomStyle", "borderTopS
 });
 
 function getElementStyles() {
-       var style = document.defaultView
-                       ? document.defaultView.getComputedStyle(this, null)
+       var style = this.ownerDocument.defaultView
+                       ? this.ownerDocument.defaultView.getComputedStyle( this, null )
                        : this.currentStyle,
                newStyle = {},
                key,