cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From coli...@apache.org
Subject cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript/v2 ScriptableWidget.java
Date Wed, 14 Apr 2004 21:25:41 GMT
coliver     2004/04/14 14:25:41

  Modified:    src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript/v2
                        ScriptableWidget.java
  Log:
  allow validation error message to be null
  
  Revision  Changes    Path
  1.5       +4 -4      cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript/v2/ScriptableWidget.java
  
  Index: ScriptableWidget.java
  ===================================================================
  RCS file: /home/cvs/cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript/v2/ScriptableWidget.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- ScriptableWidget.java	20 Mar 2004 22:45:31 -0000	1.4
  +++ ScriptableWidget.java	14 Apr 2004 21:25:41 -0000	1.5
  @@ -503,7 +503,7 @@
           return wrap(sub);
       }
   
  -    public void jsFunction_setValidationError(String message, 
  +    public void jsFunction_setValidationError(Object message /* null to clear error */,

                                                 Object parameters) {
           if (delegate instanceof ValidationErrorAware) {
               String[] parms = null;
  @@ -520,10 +520,10 @@
               if (message != null) {
                   if (parms != null && parms.length > 0) {
                       validationError = 
  -                        new ValidationError(message, parms);
  +                        new ValidationError(Context.toString(message), parms);
                   } else {
                       validationError = 
  -                        new ValidationError(message, parms != null);
  +                        new ValidationError(Context.toString(message), parms != null);
                   }
               }
               ((ValidationErrorAware)delegate).setValidationError(validationError);
  
  
  

Mime
View raw message