<%-- /* * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ --%> <%@ page import='org.apache.wookie.helpers.FlashMessage' %> <%@ page import='org.apache.wookie.Messages,org.apache.wookie.beans.IWidget,java.util.ArrayList,java.util.Enumeration,java.util.Hashtable;' %> <%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%> <% Messages localizedMessages = (Messages)session.getAttribute(Messages.class.getName()); %> <%=localizedMessages.getString("webmenu.listall.0")%>
<% Hashtable widgetsHash = (Hashtable)request.getAttribute("widgetsHash"); ArrayList guids = new ArrayList(); int count = -1; for(Enumeration e = widgetsHash.keys(); e.hasMoreElements();){ String id = (String) e.nextElement(); IWidget widget = (IWidget) widgetsHash.get(id); if (!widget.getGuid().equalsIgnoreCase("http://www.tencompetence.org/widgets/default/notsupported")){ String guid = widget.getGuid(); if(!guids.contains(guid)){ guids.add(guid); ++count; %> <% if (count==2){ %><% count=-1; } } } }%>
<%=widget.getWidgetTitle()%>
<%=widget.getWidgetDescription()%>
<% FlashMessage.clearErrorsAndMessages(session);%>