diff options
author | Matti Hosio <mhosio@vaadin.com> | 2014-12-11 09:05:19 +0200 |
---|---|---|
committer | Matti Hosio <mhosio@vaadin.com> | 2014-12-12 09:49:00 +0200 |
commit | 64a029571955ee52b0c416b597fb718bc0a66c46 (patch) | |
tree | 60b143e1cbd3915bc0c9cc382e58907ba84f128f /server/src/com/vaadin/ui/TextArea.java | |
parent | 775276d4a987844fbbb88730f0eb11e285ae6e09 (diff) | |
download | vaadin-framework-64a029571955ee52b0c416b597fb718bc0a66c46.tar.gz vaadin-framework-64a029571955ee52b0c416b597fb718bc0a66c46.zip |
Declarative support for TextField, PasswordField and TextArea (#7749)
Change-Id: I41d04c55c65820f0270742468e94f47099783950
Diffstat (limited to 'server/src/com/vaadin/ui/TextArea.java')
-rw-r--r-- | server/src/com/vaadin/ui/TextArea.java | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/server/src/com/vaadin/ui/TextArea.java b/server/src/com/vaadin/ui/TextArea.java index e38be8ad3c..70b9268228 100644 --- a/server/src/com/vaadin/ui/TextArea.java +++ b/server/src/com/vaadin/ui/TextArea.java @@ -16,8 +16,11 @@ package com.vaadin.ui; +import org.jsoup.nodes.Element; + import com.vaadin.data.Property; import com.vaadin.shared.ui.textarea.TextAreaState; +import com.vaadin.ui.declarative.DesignContext; /** * A text field that supports multi line editing. @@ -133,4 +136,30 @@ public class TextArea extends AbstractTextField { return getState(false).wordwrap; } + /* + * (non-Javadoc) + * + * @see + * com.vaadin.ui.AbstractField#synchronizeFromDesign(org.jsoup.nodes.Element + * , com.vaadin.ui.declarative.DesignContext) + */ + @Override + public void synchronizeFromDesign(Element design, + DesignContext designContext) { + super.synchronizeFromDesign(design, designContext); + setValue(design.html()); + } + + /* + * (non-Javadoc) + * + * @see + * com.vaadin.ui.AbstractTextField#synchronizeToDesign(org.jsoup.nodes.Element + * , com.vaadin.ui.declarative.DesignContext) + */ + @Override + public void synchronizeToDesign(Element design, DesignContext designContext) { + super.synchronizeToDesign(design, designContext); + design.html(getValue()); + } } |