﻿/*::::::::::::::::::::::::::::::::::::::::::::
	Parrish Medical Center
	Designed by Angie Thompson
	HTML/CSS/JS by Brandon Kidd
	Home JS
	Copyright © 2010 McMurry
::::::::::::::::::::::::::::::::::::::::::::*/

(function($) {
	$(function() {
		// jQuery
		
		// Marquee
//		$('#wrap').removeClass('parrish');
//		$('#wrap').before('<div id="marquee-wrap"></div>');
//		$('#marquee-wrap').append('<div class="slide slide1"></div><div class="slide slide2"></div><div class="slide slide3"></div>');
//		$('#marquee-wrap').cycle({ fx: 'fade', speed: '300', timeout: '5000' });
		
		// Featured Videos
		//if($('#content .featured-videos .video').length > 1){
			//$('#content .featured-videos .video-list').after('<a href="javascript:void(0);" class="btn-nextvideo">Next &raquo;</a>');
			//$('#content .featured-videos .video-list').cycle({ fx: 'fade', next: '.btn-nextvideo', speed: '500', timeout: 0, cleartype: true });
		//}
		//var params = {};
		//var flashvars = {};
		//params.align = "center";
		//params.allowscriptaccess = "always";
		//params.allowfullscreen = "false";
		//params.bgcolor = "#000000";
		//params.wmode = "transparent";
		//params.flashvars = "intl_lang=en-us&photo_secret=a6878348f9&photo_id=4538154056";
		//swfobject.embedSWF("http://www.myfoxorlando.com/video/videoplayer.swf?dppversion=6512", "featured-video1", "270", "200", "8", "false", flashvars, params);

		// InQuickER Modal
		$('#content .cta-inquicker-soon').click(function () {
			$('body').prepend('<div class="screen"></div>');
			$('body').css('overflow', 'hidden');
			$('.screen').css({ 'width': $(document).width(), 'height': $(document).height(), 'backgroundColor': '#000', 'opacity': '0', 'position': 'absolute', 'left': '0px', 'top': '0px', 'z-index': '400' });
			$('.screen').animate({
				opacity: '0.5'
			}, 'fast', function () {
				$('#modal-inquicker-soon').fadeIn('fast', function () {
					$('#modal-inquicker-soon, .screen').click(function () {
						$('#modal-inquicker-soon').fadeOut('fast', function () {
							$('.screen').animate({
								opacity: '0'
							}, 'fast', function () {
								$('.screen').remove();
								$('body').css('overflow', 'visible');
							});
						});
					});
				});
			});
		});
		
		// Health Assessments
		if($('#content .health-assessments .health-ctas ul li').length > 1){
			$('#content .health-assessments .health-ctas').before('<a href="javascript:void(0);" class="btn btn-leftarrow">Previous</a><a href="javascript:void(0);" class="btn btn-rightarrow">Next</a>');
			$('#content .health-assessments .health-ctas').scrollable({ clickable: false, items: 'ul', next: '.btn-rightarrow', prev: '.btn-leftarrow', size: 1, speed: 500 }).circular();
		}
	});
})(jQuery);

DD_roundies.addRule('#content .featured-videos, #content .recent-updates, #content .upcoming-events, #content .health-assessments', '10px');
DD_roundies.addRule('#content .upcoming-events .event', '8px');
