<?ggf
/*
	Create the form in the HTML dialog box
*/
	form.addColorButton("textcolor","Text Color","#000000");
	form.addColorButton("bgcolor","Background Color","#ffffff");
	form.addCheckBox("borderless","Borderless Fullscreen",false);
	// define possible output formats
	form.addOutputFormat("HTML (.html)","html");
	form.addOutputFormat("HTML (.htm)","htm");
	
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
		<title><?ggs document.writeEncoded(document.expandVariables(config.userdata.title)); ?></title>
<?ggs
	document.addfile("../3rdparty/swfobject/swfobject.js","swfobject.js");
?>
		<script type="text/javascript" src="swfobject.js">
		</script>
		<style type="text/css" title="Default">
			body, div, h1, h2, h3, span, p {
				font-family: Verdana,Arial,Helvetica,sans-serif;
				color: <?ggs document.write(formvalue["textcolor"]); ?>; 
			}
			body {
				/* fullscreen */
				margin: 0px;
<?ggs if (formvalue["borderless"]=="true") {  ?>
				overflow:hidden; /* disable scrollbars */
<?ggs }  ?>
			}
			html, body {
				height:100%;
				font-size: 10pt;
				background : <?ggs document.write(formvalue["bgcolor"]); ?>; 
			}
			h1 {
				font-size: 18pt;
			}
			h2 {
				font-size: 14pt;
			}
			.warning {
				font-weight: bold;
			}
		</style>	
	</head>
	<body>
		<script type="text/javascript">
<!--
			var flashvars = {};
			var params = {};
<?ggs
	var flashversion=output.version;
	if (flashversion<8) flashversion=8;
	
	if (formvalue["_gg_panorama"]) {
			panostr=formvalue["_gg_panorama"].toString();
//			panostr=panostr.replace("\n","';\n\t\t\t\tpanorama+='");
			arr=panostr.split("\n");
			panostr=arr.join("';\n\t\t\tpanorama+='");
?>
				// embedded panorama data 
			panorama='<?ggs document.write(panostr); ?>';
			flashvars.panorama=escape(panorama);
<?ggs
	}	
	if (formvalue["_gg_skin"]) {
			skinstr=formvalue["_gg_skin"].toString();
			skinstr=skinstr.split("'").join("&#39;"); // workaround for .replace
			skinstr=skinstr.split("\n").join("';\n\t\t\tskin+='");
?>
				// embedded skin data 
			skin='<?ggs document.write(skinstr); ?>';
			flashvars.skin=escape(skin);
<?ggs
	}
?>
			params.quality = "high";
			params.bgcolor = "<?ggs document.write(formvalue["bgcolor"]); ?>";
			params.allowscriptaccess = "sameDomain";
			params.allowfullscreen = "true";
			params.base="<?ggs document.write(outputbase); ?>";
			var attributes = {};
			attributes.id = "pano";
			attributes.name = "pano";
			attributes.align = "middle";
			swfobject.embedSWF(
				"<?ggs document.write(document.encodeUrlUtf8(outputfile)); ?>", "flashContent", 
				"100%", "<?ggs document.write((formvalue['borderless']=="true")?'100%':'95%'); ?>", 
				"9.0.0", "expressInstall.swf", 
				flashvars, params, attributes);
//-->
		</script>
		<div id="flashContent">
			<p><a href="http://www.adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>
		</div>
		<noscript>
			<p class="warning">Please enable Javascript!</p>
		</noscript>
<?ggs 
	if (formvalue["borderless"]=="false") {
?>
		<p align="center">
			<a href="javascript:close();">close</a>
		</p>	
<?ggs 
	}
?>
	</body>
</html>
