
// Flash printing functions

function WriteFlashMap() {
	var flashURL = "/mds/media/Flash/map.swf";
	var width = 900;
	var height = 536;
	
	printFlash(flashURL, width, height);
	
}
function WriteHomeFlash() {
	//var flashURL = "/mds/media/Flash/homepage.swf";
	var flashURL = "/KevinAsbjornson_Home_Flash.swf";
	var width = 651;
	var height = 331;
	
	printFlash(flashURL, width, height);
}
function WriteImageGallery(listName, contentID) {
	var flashURL = "/mds/media/Flash/ImageGallery2.swf?xmlpath=/Constellation/xml_list.aspx%3Flistname="+listName+"%26ownertype=content%26ownerid="+contentID;
	var width = 560;
	var height = 520;
	
	printFlash(flashURL, width, height, true);
}
function WriteImageGallery2(listName, contentID) {
	var flashURL = "/mds/media/Flash/ImageGallery3.swf?xmlpath=/Constellation/xml_list.aspx%3Flistname="+listName+"%26ownertype=content%26ownerid="+contentID;
	var width = 596;
	var height = 450;
	
	printFlash(flashURL, width, height, true);
}
   
    
function printFlash(flashURL, width, height) {

	var bgcolor = "#FFFFFF";
	var allowScriptAccess = "sameDomain";
	var quality = "high";
	var align = "middle";
	var name = "flash";
	var autoplay = true;

	document.writeln("<object classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" codebase=\"http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0\" width=\""+width+"\" height=\""+height+"\" id=\""+name+"\" align=\""+align+"\">");
	document.writeln("<param name=\"allowScriptAccess\" value=\""+allowScriptAccess+"\" />");
	document.writeln("<param name=\"movie\" value=\""+flashURL+"\" />");
	document.writeln("<param name=\"quality\" value=\""+quality+"\" />");
	document.writeln("<param name=\"bgcolor\" value=\""+bgcolor+"\" />");
	document.writeln("<param name=\"play\" value=\""+autoplay+"\" />");
	document.write("<embed src=\""+flashURL+"\" quality=\""+quality+"\" bgcolor=\""+bgcolor+"\" width=\""+width+"\" height=\""+height+"\" name=\""+name+"\" align=\""+align+"\" allowScriptAccess=\""+allowScriptAccess+"\"");
	document.write("play=\""+autoplay+"\" ");
	document.writeln("type=\"application/x-shockwave-flash\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\" />");
	document.writeln("</object>");
}


function printFlashVideo(video, width, height) {
	document.writeln("<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0\" width=\"" + width + "\" height=\"" + height + "\" id=\"FlowPlayer\">");
	document.writeln("<param name=\"movie\" value=\"/mds/media/flash/FlowPlayer.swf\" />");
	document.writeln("<param name=\"salign\" value=\"lt\" />");
	document.writeln("<param name=\"quality\" value=\"high\" />");
	document.writeln("<param name=\"scale\" value=\"noscale\" />");
	document.writeln("<param name=\"allowFullScreen\" value=\"true\" />");
	document.writeln("<param name=\"FlashVars\" value=\"config={ playList: [ " + video + " ], initialScale: 'fit', menuItems: [ true, true, true, true, true, false ], useNativeFullScreen: true, loop: false }\" />");
	document.writeln("<embed src=\"/mds/media/flash/FlowPlayer.swf\" flashvars=\"config={ playList: [ " + video + " ], initialScale: 'fit', menuItems: [ true, true, true, true, true, false ], useNativeFullScreen: true, loop: false }\" quality=\"high\" scale=\"noscale\" width=\"" + width + "\" height=\"" + height + "\" name=\"FlowPlayer\" salign=\"LT\" type=\"application/x-shockwave-flash\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\" allowFullScreen=\"true\" />");
	document.writeln("</object>");
	FlowPlayer = document.getElementById('FlowPlayer');	
}