portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tay...@apache.org
Subject svn commit: r889076 - /portals/jetspeed-2/applications/j2-admin/trunk/src/main/webapp/WEB-INF/view/spaces/space-navigator.jsp
Date Thu, 10 Dec 2009 03:39:48 GMT
Author: taylor
Date: Thu Dec 10 03:39:47 2009
New Revision: 889076

URL: http://svn.apache.org/viewvc?rev=889076&view=rev
Log:
https://issues.apache.org/jira/browse/JS2-1084
- rewrote Spaces navigator using styles contributed by Robbert Kauffman

Modified:
    portals/jetspeed-2/applications/j2-admin/trunk/src/main/webapp/WEB-INF/view/spaces/space-navigator.jsp

Modified: portals/jetspeed-2/applications/j2-admin/trunk/src/main/webapp/WEB-INF/view/spaces/space-navigator.jsp
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/applications/j2-admin/trunk/src/main/webapp/WEB-INF/view/spaces/space-navigator.jsp?rev=889076&r1=889075&r2=889076&view=diff
==============================================================================
--- portals/jetspeed-2/applications/j2-admin/trunk/src/main/webapp/WEB-INF/view/spaces/space-navigator.jsp
(original)
+++ portals/jetspeed-2/applications/j2-admin/trunk/src/main/webapp/WEB-INF/view/spaces/space-navigator.jsp
Thu Dec 10 03:39:47 2009
@@ -26,34 +26,33 @@
 <%@ taglib uri="http://java.sun.com/portlet" prefix="portlet"%>
 
 <portlet:defineObjects/>
-
-  <div class="yui-menu-content">
-    <ul class="first-of-type">
-      <li><a class="yui-menu-label" href="#intranet-spaces-menu"><em><%=
((Space)renderRequest.getAttribute("space")).getName() %></em></a>
-        <div id="intranet-spaces-menu" class="yui-menu">
-          <div class="yui-menu-content">
-            <ul class="first-of-type">
 <%
+	Space current = ((Space)renderRequest.getAttribute("space"));
+%>
+		<ul id="nav-top">
+			<li><a href="<portlet:actionURL><portlet:param name='space' value='<%=current.getName()%>'/></portlet:actionURL>"
title="<%= current.getName() %>"><%= current.getName() %></a>
+				<ul id="spaceList">
+<%
+  int count = 0;
   List<Space> spaces = (List<Space>)renderRequest.getAttribute("spaces");
-  for (Space space : spaces) {
+  
+  for (Space space : spaces) 
+  {
+      String style = null;
+      String extStyle = null;
+      if (count == 0) style = "first";
+      else if (count == spaces.size() -1) style = "last";
+      if (space.getName().equals(current.getName()))
+      {
+          extStyle = "font-weight: bold";
+      }
 %>     
-              <li class="yui-menuitem">
-                <a class="yui-menuitem-content" href="<portlet:actionURL><portlet:param
name='space' value='<%=space.getName()%>'/></portlet:actionURL>"><%=space.getName()
%></a>
-              </li>
-<%}%>
-            </ul>
+<li <% if (style != null) { %>class="<%=style%>" <% } %>><a  <%
if (extStyle != null) { %>style="<%=extStyle%>" <% } %>   href="<portlet:actionURL><portlet:param
name='space' value='<%=space.getName()%>'/></portlet:actionURL>" title="<%=space.getName()
%>"><%=space.getName() %></a></li>
 <%
-  Object princ = renderRequest.getUserPrincipal();
-  if (princ != null) {
+  count++;
+  }
 %>
-            <ul>
-              <li class="yui-menuitem">
-                <a class="yui-menuitem-content" href="<portlet:actionURL><portlet:param
name='navAction' value='addSpace'/></portlet:actionURL>">Add Space...</a>
-              </li>
-            </ul>
-<%}%>
-          </div>
-        </div>
-      </li>
-    </ul>
-  </div>
+			<li class="add"><a href="<portlet:actionURL><portlet:param name='navAction'
value='addSpace'/></portlet:actionURL>" title="Add Space">Add Space</a></li>
+				</ul>
+			</li>
+		</ul>
\ No newline at end of file



---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


Mime
View raw message