<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>

<html>
<f:view>
	<head>
	<f:loadBundle basename="message" var="msg" />
	<title></title>

	<script type="text/javascript">
		function showEvent(elementID, value) {
			var oldObject = window.document.getElementById(elementID);
			if(oldObject == null || oldObject.type == "text") return;
			var newObject = window.document.createElement('input');
			if(oldObject.type) newObject.type = "text";
			if(oldObject.size) newObject.size = oldObject.size;
			if(oldObject.value) newObject.value = value;
			if(oldObject.id) newObject.id = oldObject.id;
			oldObject.parentNode.replaceChild(newObject,oldObject);
		}
	</script>
	<link rel="stylesheet"
		href="<%=request.getContextPath()%>/styles/styles.css" type="text/css" />
	</head>
	<body>
	<div id="divOpthID" align="right" style="z-index: 200"><jsp:include
		page="/pages/RichMenu/RichMenu.jsp" /></div>
	<h:form id="formID">
		<h:panelGrid id="richGridID" columns="1">
			<h:column rendered="#{richBean.reComponent}">
				<jsp:include page="${richBean.pathComponent}" />
			</h:column>
			<h:column rendered="#{!richBean.reComponent}"></h:column>

			<h:column rendered="#{richBean.reStraightforward}">
				<jsp:include page="${richBean.pathStraightforward}" />
			</h:column>
			<h:column rendered="#{!richBean.reStraightforward}"></h:column>

			<h:column rendered="#{richBean.reProperty}">
				<jsp:include page="${richBean.pathProperty}" />
			</h:column>
			<h:column rendered="#{!richBean.reProperty}"></h:column>
		</h:panelGrid>
	</h:form>
	<rich:modalPanel id="eventInfoID" autosized="true" minHeight="550"
		minWidth="200" moveable="true" style="overflow: true;">
		<f:facet name="header">
			<h:outputText value="Events ..." />
		</f:facet>
		<f:facet name="controls">
			<h:graphicImage value="/pics/error.gif"
				onclick="Richfaces.hideModalPanel('eventInfoID');" />
		</f:facet>

		<jsp:include page="/pages/Action/EventInfo.jsp" />

	</rich:modalPanel>
	<a4j:commandButton value="Show event"
		onclick="Richfaces.showModalPanel('eventInfoID');return false;"></a4j:commandButton>
	</body>
</f:view>
</html>
