[jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui/facelet ...

Gavin King gavin.king at jboss.com
Sat Feb 17 12:24:52 EST 2007


  User: gavin   
  Date: 07/02/17 12:24:52

  Modified:    src/ui/org/jboss/seam/ui/facelet  SeamExpressionFactory.java
  Log:
  extend hack to valuechangeevents
  
  Revision  Changes    Path
  1.7       +8 -6      jboss-seam/src/ui/org/jboss/seam/ui/facelet/SeamExpressionFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamExpressionFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/facelet/SeamExpressionFactory.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- SeamExpressionFactory.java	19 Nov 2006 17:36:11 -0000	1.6
  +++ SeamExpressionFactory.java	17 Feb 2007 17:24:52 -0000	1.7
  @@ -22,15 +22,16 @@
   
   package org.jboss.seam.ui.facelet;
   
  -import com.sun.facelets.compiler.SAXCompiler;
   import javax.el.ELContext;
   import javax.el.ExpressionFactory;
   import javax.el.MethodExpression;
   import javax.el.ValueExpression;
  -import javax.faces.event.ActionEvent;
  +import javax.faces.event.FacesEvent;
   
   import org.jboss.seam.actionparam.MethodExpressionParser;
   
  +import com.sun.facelets.compiler.SAXCompiler;
  +
   /**
    * This ExpressionFactory replaces the one normally used in Facelets.  It
    * recognizes if an EL expression is using params.  If so, it will return a
  @@ -77,8 +78,7 @@
           {
               return new ParamMethodExpression(parser, elContext);
           }
  -        
  -        if ( paramTypes.length==1 && ActionEvent.class.isAssignableFrom( paramTypes[0] ) )
  +        else if ( paramTypes.length==1 && FacesEvent.class.isAssignableFrom( paramTypes[0] ) )
           {
              //so that JSF action listeners don't have to declare 
              //the totally frickin useless ActionEvent parameter
  @@ -87,9 +87,11 @@
                    faceletsExpressionFactory.createMethodExpression(elContext, expression, returnType, new Class[0])
                 );
           }
  -        
  +        else
  +        {
           return faceletsExpressionFactory.createMethodExpression(elContext, expression, returnType, paramTypes);
       }
  +    }
       
       @Override
       public ValueExpression createValueExpression(Object instance, Class expectedType) 
  
  
  



More information about the jboss-cvs-commits mailing list