From bbbdd947256a3fcd788fb9d4f306046082a1ef1f Mon Sep 17 00:00:00 2001 From: Michał Gołębiowski Date: Tue, 27 Aug 2013 00:54:13 +0200 Subject: Fix #10814. Make support tests lazy and broken out to components. --- src/core/swap.js | 29 ----------------------------- 1 file changed, 29 deletions(-) delete mode 100644 src/core/swap.js (limited to 'src/core') diff --git a/src/core/swap.js b/src/core/swap.js deleted file mode 100644 index 95f4e2c69..000000000 --- a/src/core/swap.js +++ /dev/null @@ -1,29 +0,0 @@ -define([ - "../core" -], function( jQuery ) { - - // A method for quickly swapping in/out CSS properties to get correct calculations. - // Note: this method belongs to the css module but it's needed here for the support module. - // If support gets modularized, this method should be moved back to the css module. - jQuery.swap = function( elem, options, callback, args ) { - var ret, name, - old = {}; - - // Remember the old values, and insert the new ones - for ( name in options ) { - old[ name ] = elem.style[ name ]; - elem.style[ name ] = options[ name ]; - } - - ret = callback.apply( elem, args || [] ); - - // Revert the old values - for ( name in options ) { - elem.style[ name ] = old[ name ]; - } - - return ret; - }; - - return jQuery.swap; -}); -- cgit v1.2.3