(function(d){var c="deg";d.fn.rotate=function(g){var f=d(this).css("transform")||"none";if(typeof g=="undefined"){if(f){var e=f.match(/rotate\(([^)]+)\)/);if(e&&e[1]){return e[1]}}return 0}var e=g.toString().match(/^(-?\d+(\.\d+)?)(.+)?$/);if(e){if(e[3]){c=e[3]}d(this).css("transform",f.replace(/none|rotate\([^)]*\)/,"")+"rotate("+e[1]+c+")")}};d.fn.scale=function(i,h,f){var g=d(this).css("transform");if(typeof i=="undefined"){if(g){var e=g.match(/scale\(([^)]+)\)/);if(e&&e[1]){return e[1]}}return 1}d(this).css("transform",g.replace(/none|scale\([^)]*\)/,"")+"scale("+i+")")};var b=d.fx.prototype.cur;d.fx.prototype.cur=function(){if(this.prop=="rotate"){return parseFloat(d(this.elem).rotate())}else{if(this.prop=="scale"){return parseFloat(d(this.elem).scale())}}return b.apply(this,arguments)};d.fx.step.rotate=function(e){d(e.elem).rotate(e.now+c)};d.fx.step.scale=function(e){d(e.elem).scale(e.now)};var a=d.fn.animate;d.fn.animate=function(f){if(typeof f.rotate!="undefined"){var e=f.rotate.toString().match(/^(([+-]=)?(-?\d+(\.\d+)?))(.+)?$/);if(e&&e[5]){c=e[5]}f.rotate=e[1]}return a.apply(this,arguments)}})(jQuery);
