﻿


$(function(){
DD_roundies.addRule('.contentBlock', '10px', true);
DD_roundies.addRule('.homeContent', '0 0 10px 10px', true);
DD_roundies.addRule('.innerSplitCol', '5px', true);
DD_roundies.addRule('.inner', '5px', true);
DD_roundies.addRule('.innerOneCol', '5px', true);
DD_roundies.addRule('.innerTwoCol', '5px', true);
DD_roundies.addRule('h1.listHeading', '5px', true);
DD_roundies.addRule('.headingBlock', '5px', true);
DD_roundies.addRule('.hubNav .nav', '10px', true);
DD_roundies.addRule('.hubNavContent', '10px', true);
DD_roundies.addRule('.hubContent', '10px', true);
DD_roundies.addRule('.hubContent h1', '5px 5px 0px 0px', true);
DD_roundies.addRule('#CAPToolbar', '0px 0px 5px 5px', true);
});

$(function(){
	// button rollover
	if ($('.imgBtn') != null) {
		$('.imgBtn').hover(function(){
				if(!$(this).is('.disabled'))
					$(this).attr("src", $(this).attr("src").replace(/^(.*?)(?:-hover)?(\..*?)$/i,'$1-hover$2'));
			},
			function(){
					if(!$(this).is('.disabled'))
						$(this).attr("src", $(this).attr("src").replace(/^(.*)-hover(\..*?)$/i, '$1$2'));
				});
	}
	// preload image rollovers
	if ($("img.imgBtn, img[src^='images/buttons/btn'], input[src^='images/buttons/btn']") != null) {
	    $("img.imgBtn, img[src^='images/buttons/btn'], input[src^='images/buttons/btn']").each(function(){
			    $("<img>").attr("src", $(this).attr("src").replace(/(btn-.*)(\..*?)/i, '$1-hover$2'));
		    });
	}
});
