<?xml version="1.0" encoding="utf-8" ?>
<jsp:root version="1.2" 
    xmlns:jsp="http://java.sun.com/JSP/Page"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:ice="http://www.icesoft.com/icefaces/component">
	
    <jsp:directive.page contentType="text/html;charset=utf-8" />

<f:view>
    <ice:outputDeclaration doctypeRoot="HTML"
			doctypePublic="-//W3C//DTD HTML 4.01 Transitional//EN"
			doctypeSystem="http://www.w3.org/TR/html4/loose.dtd" />
    <html>
	    <head>
	       <ice:outputStyle href="./xmlhttp/css/rime/rime.css" />
		   <title>van Helsing</title>
		</head>

		<body>
		<h1 style="color:grey">van Helsing</h1>
	<ice:panelDivider dividerPosition="45" style="float:left; height:85%">
	<f:facet name="first" style="height:85%">
		<ice:panelGroup style="exampleBox;float:left;width:350px; height:85%">
		    <ice:form>
		    	<ice:tree id="baum"	
		    			value="#{configurationBean.tree}" 
		    			var="item"
		    			hideRootNode = "false"
		    			hideNavigation ="false"
		    			imageDir = "css/images/">
		    				
		    		<ice:treeNode id="knoten">
		    			<f:facet name="icon">
		    					<ice:panelGroup style="display: inline" >
			                    <ice:graphicImage
			                         value="/css/images/#{item.userObject.icon}"/>
              					</ice:panelGroup>
		    			</f:facet>
		    			<f:facet name="content">
		    			<!-- <ice:panelGroup> -->
							<!-- styleClass="selectedNode#{item.userObject eq treeController.selectedUserObject}"
							style="display: inline" > -->
						<ice:commandLink actionListener="#{configurationBean.userObjectItemNodeSelected}">
		    				<f:param name="userObject.resId" value="#{item.userObject.userObject.resId}"/>
		    			    <ice:outputText id="knoten" value="#{item.userObject.userObject.value}"/>
		    			</ice:commandLink>
		    			<!-- </ice:panelGroup> -->
		    			</f:facet>
		    		</ice:treeNode>
		    	</ice:tree>
		    </ice:form>
		</ice:panelGroup>
		</f:facet>
		<f:facet name="second">
		
		<ice:panelGroup style="float:left;margin: 0; padding: 0" >
                <ice:panelGroup rendered="#{configurationBean.selectedObject != null}">
                	<ice:commandButton id="newRes" 
                			value="Neu2" 
                			actionListener="#{configurationBean.newResourceButtonListener}"/>
	       			<ice:commandButton id="saveRes"
	                           value="Speichern"
	                           actionListener="#{configurationBean.saveButtonListener}"/>
                </ice:panelGroup>
    	
			<ice:panelGrid cellpadding="0" cellspacing="3" 
				columns="2" rendered="#{configurationBean.selectedObject != null}">
				<ice:form>
				<ice:dataTable
				        var="item"
				         value="#{configurationBean.selectedObject}"
				         >
				        <ice:column>
				                <f:facet name="header">
				                         <ice:outputText value="Key" />
				                 </f:facet>
				                <ice:outputText value="#{item.key}" />
				        </ice:column>
				        <ice:column>
				                <f:facet name="header">
				                         <ice:outputText value="Value" />
				                </f:facet>
				                <ice:inputText rendered="#{item.inputText != null}" partialSubmit="true" value="#{item.keyValue}" />
								<ice:selectOneMenu id="SlctCompTyp" rendered="#{item.inputSelectOne != null}" valueChangeListener="#{selectionTags.effectChangeListener}"
                        			value="#{selectionTags.selectedComponent}" partialSubmit="true">
                    				<f:selectItems id="SlctcompTypeItms" value="#{selectionTags.componentItems}"/>
                				</ice:selectOneMenu>								
				        </ice:column>
				     
				</ice:dataTable>
            </ice:form> 				
			</ice:panelGrid>		
		</ice:panelGroup>
		</f:facet>
		</ice:panelDivider>
		<ice:panelDivider style="float:left; width:450px; height:85%">
		<f:facet name="first"></f:facet>
		<f:facet name="second">blub</f:facet>
		</ice:panelDivider>
	    <ice:form>
		    <ice:messages/>     
	    </ice:form>
		</body>
    </html>
</f:view>
</jsp:root>