	(function(jQuery) {
		jQuery.fn.styleSwitcher = function() {
			jQuery(this).click(function() {
			jQuery('body').css('height', '100%'); // IE6 Hack
			jQuery('<div id="overlay" ></div>').appendTo('body').fadeIn(300);
						
				jQuery.ajax({
					type: 'get',
					url: jQuery(this).attr('href'),
					data: 'js=1',
					
					success: function(r) {
						 jQuery('#ss').attr('href', 'http://www.wpnoise.com/wp-content/themes/closerlook/stylesheets/' + r + '.css');
						 Verify_Loaded_Css.check(function() {
							 jQuery('#overlay').fadeOut(300, function() {
								jQuery(this).remove();
							 });	
						 });
					}
				}); // end ajax
				
				return false;
			}); // end click
			
				var Verify_Loaded_Css = {
					init: function() {
						jQuery('<div id="test" style="display: none;" />').appendTo('body');
					},
					check: function(runCallback) {
						if (jQuery('#test').width() == 2) runCallback();
						else setTimeout(function() {Verify_Loaded_Css.check(runCallback)}, 300);
					}
				}			
			
			Verify_Loaded_Css.init();
		};
	})(jQuery);
		