dlestrat    2004/11/16 17:07:47

  Modified:    
portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces
                        PortletExternalContextImpl.java
                        PortletViewHandlerImpl.java
                        PortletFacesContextImpl.java
               portals-bridges/myfaces project.xml
               portal/src/webapp/WEB-INF/decorations/portlet/html/tigris/css
                        styles.css
  Added:       
portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces
                        NullIterator.java EnumerationIterator.java
               portals-bridges/myfaces locator.ent
  Log:
  http://nagoya.apache.org/jira/browse/JS2-159
  
  Revision  Changes    Path
  1.5       +4 -2      
jakarta-jetspeed-2/portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces/PortletExternalContextImpl.java
  
  Index: PortletExternalContextImpl.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-jetspeed-2/portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces/PortletExternalContextImpl.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- PortletExternalContextImpl.java   16 Sep 2004 06:27:25 -0000      1.4
  +++ PortletExternalContextImpl.java   17 Nov 2004 01:07:46 -0000      1.5
  @@ -37,8 +37,6 @@
   import javax.portlet.RenderRequest;
   import javax.portlet.RenderResponse;
   
  -import net.sourceforge.myfaces.util.EnumerationIterator;
  -
   import org.apache.commons.logging.LogFactory;
   import org.apache.commons.logging.Log;
   
  @@ -377,6 +375,10 @@
        */
       public String encodeResourceURL(String s)
       {
  +        if ((null != s) && (!s.startsWith("http") && (!s.startsWith("/"))))
  +        {
  +            s = "/" + s;
  +        }
           return this.portletResponse.encodeURL(s);
       }
   
  
  
  
  1.7       +8 -1      
jakarta-jetspeed-2/portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces/PortletViewHandlerImpl.java
  
  Index: PortletViewHandlerImpl.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-jetspeed-2/portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces/PortletViewHandlerImpl.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- PortletViewHandlerImpl.java       30 Oct 2004 01:09:01 -0000      1.6
  +++ PortletViewHandlerImpl.java       17 Nov 2004 01:07:46 -0000      1.7
  @@ -113,7 +113,14 @@
        */
       public String getResourceURL(FacesContext facesContext, String path)
       {
  -        return handler.getResourceURL(facesContext, path);
  +        if (path.length() > 0 && path.charAt(0) == '/')
  +        {
  +            return facesContext.getExternalContext().getRequestContextPath() 
+ path;
  +        }
  +        else
  +        {
  +            return facesContext.getExternalContext().getRequestContextPath() 
+ "/" + path;
  +        }
       }
   
       /**
  
  
  
  1.5       +0 -2      
jakarta-jetspeed-2/portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces/PortletFacesContextImpl.java
  
  Index: PortletFacesContextImpl.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-jetspeed-2/portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces/PortletFacesContextImpl.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- PortletFacesContextImpl.java      15 Oct 2004 22:58:43 -0000      1.4
  +++ PortletFacesContextImpl.java      17 Nov 2004 01:07:46 -0000      1.5
  @@ -39,8 +39,6 @@
   import javax.portlet.PortletResponse;
   import javax.portlet.PortletSession;
   
  -import net.sourceforge.myfaces.util.NullIterator;
  -
   /**
    * <p>
    * See MyFaces project for servlet implementation.
  
  
  
  1.1                  
jakarta-jetspeed-2/portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces/NullIterator.java
  
  Index: NullIterator.java
  ===================================================================
  /*
   * Copyright 2004 The Apache Software Foundation.
   * 
   * 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.
   */
  package org.apache.portals.bridges.myfaces;
  
  import java.util.Iterator;
  import java.util.NoSuchElementException;
  
  /**
   * <p>
   * Iterator without elements.
   * </p>
   * <p>
   * Code borrowed from myfaces.
   * </p>
   */
  public final class NullIterator implements Iterator
  {
      private static final NullIterator INSTANCE = new NullIterator();
  
      public static final Iterator instance()
      {
          return INSTANCE;
      }
  
      public boolean hasNext()
      {
          return false;
      }
  
      public Object next()
      {
          throw new NoSuchElementException();
      }
  
      public void remove()
      {
          throw new UnsupportedOperationException(this.getClass().getName() + " 
UnsupportedOperationException");
      }
  }
  
  
  
  1.1                  
jakarta-jetspeed-2/portals-bridges/myfaces/src/java/org/apache/portals/bridges/myfaces/EnumerationIterator.java
  
  Index: EnumerationIterator.java
  ===================================================================
  /*
   * Copyright 2004 The Apache Software Foundation.
   * 
   * 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.
   */
  package org.apache.portals.bridges.myfaces;
  
  import java.util.Enumeration;
  import java.util.Iterator;
  
  /**
   * <p>
   * Code borrowed from myfaces.
   * </p>
   */
  public class EnumerationIterator implements Iterator
  {
      private Enumeration enumeration;
  
      public EnumerationIterator(Enumeration enumeration)
      {
          this.enumeration = enumeration;
      }
  
      public boolean hasNext()
      {
          return this.enumeration.hasMoreElements();
      }
  
      public Object next()
      {
          return this.enumeration.nextElement();
      }
  
      public void remove()
      {
          throw new UnsupportedOperationException(this.getClass().getName() + " 
UnsupportedOperationException");
      }
  }
  
  
  1.4       +6 -25     jakarta-jetspeed-2/portals-bridges/myfaces/project.xml
  
  Index: project.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed-2/portals-bridges/myfaces/project.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- project.xml       22 Oct 2004 22:43:33 -0000      1.3
  +++ project.xml       17 Nov 2004 01:07:46 -0000      1.4
  @@ -1,4 +1,8 @@
   <?xml version="1.0" encoding="UTF-8"?>
  +<!DOCTYPE project [
  +  <!ENTITY % locator-entities SYSTEM "file:locator.ent"> %locator-entities;  
  +]>
  +
   <!--
   Copyright 2004 The Apache Software Foundation
   
  @@ -67,30 +71,7 @@
         <version>2.3</version>
       </dependency>
   
  -    <dependency>
  -      <groupId>myfaces</groupId>
  -      <artifactId>myfaces-jsf-api</artifactId>
  -      <version>1.0.7-SNAPSHOT</version>
  -      <properties>
  -        <war.bundle>true</war.bundle>
  -      </properties>
  -    </dependency>
  -    <dependency>
  -      <groupId>myfaces</groupId>
  -      <artifactId>myfaces</artifactId>
  -      <version>1.0.7-SNAPSHOT</version>
  -      <properties>
  -        <war.bundle>true</war.bundle>
  -      </properties>
  -    </dependency>
  -    <dependency>
  -      <groupId>myfaces</groupId>
  -      <artifactId>myfaces-components</artifactId>
  -      <version>1.0.7-SNAPSHOT</version>
  -      <properties>
  -        <war.bundle>true</war.bundle>
  -      </properties>
  -    </dependency>
  +    &myfaces-deps;
   
       <dependency>
         <groupId>portals-bridges</groupId>
  
  
  
  1.1                  jakarta-jetspeed-2/portals-bridges/myfaces/locator.ent
  
  Index: locator.ent
  ===================================================================
  <!-- Project dependencies -->
  <!ENTITY myfaces-deps SYSTEM 
"file:../../etc/project-dependencies/myfaces-deps.xml">
  
  <!-- Project reports -->
  <!ENTITY j2-reports SYSTEM "file:../../etc/project-reports/j2-reports.xml">
  
  
  1.6       +75 -0     
jakarta-jetspeed-2/portal/src/webapp/WEB-INF/decorations/portlet/html/tigris/css/styles.css
  
  Index: styles.css
  ===================================================================
  RCS file: 
/home/cvs/jakarta-jetspeed-2/portal/src/webapp/WEB-INF/decorations/portlet/html/tigris/css/styles.css,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- styles.css        9 Nov 2004 12:33:56 -0000       1.5
  +++ styles.css        17 Nov 2004 01:07:47 -0000      1.6
  @@ -483,3 +483,78 @@
       voice-family: inherit;
       font-size: x-small;
   }
  +
  +/* --------------------------------- */
  +/* Tree component                    */
  +/* --------------------------------- */
  +th, td, input {
  +     font-family: Verdana, Helvetica, Arial, sans-serif;
  +}
  +
  +table, th, td {
  +     font-size: small;
  +     border: none;
  +}
  +
  +.treeHeader {
  +     background-color: #bbb;
  +     border: 0.75px solid #fff;
  +     padding: 2px 3px;
  +     text-align: left;
  +}
  +
  +.treeFooter {
  +     font-size: x-small;
  +     padding: 5px;
  +     margin: .67em 2px;
  +     margin-top: 0;
  +     background-color: #ddd;
  +     background-image: url(../images/sw_med_rond.gif);
  +     background-repeat: no-repeat;
  +     background-position: bottom left;
  +}
  +
  +
  +.treeRow1 td {
  +     font-size: small;
  +     background: #ddd;
  +     border-bottom: 1px solid #fff;
  +}
  +
  +.treeRow2 td {
  +     font-size: small;
  +     background: #efefef;
  +     border-bottom: 1px solid #fff;
  +}
  +
  +.treeCol1 {
  +     border-right: 1px solid #fff;
  +     padding: 2px 15px 2px 5px;
  +}
  +
  +.treeCol2 {
  +     border-left: 1px solid #fff;
  +     padding: 2px 15px 2px 5px;
  +}
  +
  +.tree {
  +   lineheight: 18px;
  +   font-family: arial, sans-serif;
  +}
  +
  +.treenode {
  +   padding: 2px 15px 2px 5px;
  +}
  +
  +.treenode a {
  +   text-decoration: none;
  +}
  +
  +.treenodeSelected {
  +   padding: 2px 15px 2px 5px;
  +}
  +
  +.treenodeSelected a {
  +   text-decoration: none;
  +   font-weight: bold;
  +}
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to