﻿var SPL = {	

	//looks for elements with a particular class and deletes them;
	//load and play another flash movie.
	//called from the end of a shoshkeles flash movie, for example,
	//by passing 'shoshkeles' and '#demo'
	changeFlash: function (stop_obj_class, start_obj) {
		var $stop_obj = $("." + stop_obj_class);
		var $start_obj = $(start_obj);
		
		$stop_obj.hide();
		
		$("#header").show()
		$("#landing-container").show();
		
		if($start_obj.attr('param') != null && $start_obj.attr('param').length > 0) {
			var options = $start_obj.attr('param').split('|');
			var settings = {
				filepath : options[0],
				width: options[1] || 560,
				height: options[2] || 400
			}
			
			$start_obj.flash({ 
				src: settings.filepath,
				width: settings.width,
				height: settings.height,
				wmode: 'transparent'
			});
		}		
	}

};
