click-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sa...@apache.org
Subject svn commit: r958348 - /click/trunk/click/extras/src/org/apache/click/extras/control/DateField.java
Date Sun, 27 Jun 2010 07:56:53 GMT
Author: sabob
Date: Sun Jun 27 07:56:52 2010
New Revision: 958348

URL: http://svn.apache.org/viewvc?rev=958348&view=rev
Log:
fixed DateField to use getter instead of direct references.

Modified:
    click/trunk/click/extras/src/org/apache/click/extras/control/DateField.java

Modified: click/trunk/click/extras/src/org/apache/click/extras/control/DateField.java
URL: http://svn.apache.org/viewvc/click/trunk/click/extras/src/org/apache/click/extras/control/DateField.java?rev=958348&r1=958347&r2=958348&view=diff
==============================================================================
--- click/trunk/click/extras/src/org/apache/click/extras/control/DateField.java (original)
+++ click/trunk/click/extras/src/org/apache/click/extras/control/DateField.java Sun Jun 27
07:56:52 2010
@@ -738,6 +738,8 @@ public class DateField extends TextField
      */
     @Override
     public void validate() {
+        String formatPattern = getFormatPattern();
+
         if (formatPattern == null) {
             String msg = "dateFormat attribute is null for field: " + getName();
             throw new IllegalStateException(msg);
@@ -774,7 +776,7 @@ public class DateField extends TextField
 
         // Set default title
         if (getTitle() == null) {
-            setTitle(getMessage("date-title", formatPattern));
+            setTitle(getMessage("date-title", getFormatPattern()));
         }
 
         // Ensure help is not rendered by super implementation



Mime
View raw message