]> source.dussan.org Git - vaadin-framework.git/commitdiff
Make TextField.clear() use empty string to be consistent with constructor (#14755)
authorArtur Signell <artur@vaadin.com>
Tue, 2 Dec 2014 19:19:06 +0000 (21:19 +0200)
committerVaadin Code Review <review@vaadin.com>
Wed, 10 Dec 2014 06:48:29 +0000 (06:48 +0000)
Change-Id: Ic50ff305277e54f50353fc948b31a89a6b3e083f

server/src/com/vaadin/ui/TextField.java

index fb1e4284a2492ee44d9e4ee450bddf997ccbf882..1fc10c6ced7835ac4382a73ccc78452da0168dbd 100644 (file)
@@ -43,7 +43,7 @@ public class TextField extends AbstractTextField {
      * Constructs an empty <code>TextField</code> with no caption.
      */
     public TextField() {
-        setValue("");
+        clear();
     }
 
     /**
@@ -99,4 +99,14 @@ public class TextField extends AbstractTextField {
         setCaption(caption);
     }
 
+    /*
+     * (non-Javadoc)
+     * 
+     * @see com.vaadin.ui.AbstractField#clear()
+     */
+    @Override
+    public void clear() {
+        setValue("");
+    }
+
 }