diff options
author | Artur Signell <artur@vaadin.com> | 2012-08-22 21:48:34 +0300 |
---|---|---|
committer | Artur Signell <artur@vaadin.com> | 2012-08-22 22:24:34 +0300 |
commit | 8d2d0adb625f478658b7115ae2dfb007aad079b5 (patch) | |
tree | b25f26f846a111a0eb557a377357568fb14ee898 /server/src/com/vaadin/ui/RichTextArea.java | |
parent | af2638fc57cf3d9f6dc84957bb6ee4b256ec60e7 (diff) | |
download | vaadin-framework-8d2d0adb625f478658b7115ae2dfb007aad079b5.tar.gz vaadin-framework-8d2d0adb625f478658b7115ae2dfb007aad079b5.zip |
Removed API deprecated in Vaadin 6 (#9071)
Diffstat (limited to 'server/src/com/vaadin/ui/RichTextArea.java')
-rw-r--r-- | server/src/com/vaadin/ui/RichTextArea.java | 71 |
1 files changed, 4 insertions, 67 deletions
diff --git a/server/src/com/vaadin/ui/RichTextArea.java b/server/src/com/vaadin/ui/RichTextArea.java index e3d1168559..e954f78700 100644 --- a/server/src/com/vaadin/ui/RichTextArea.java +++ b/server/src/com/vaadin/ui/RichTextArea.java @@ -16,7 +16,6 @@ package com.vaadin.ui; -import java.text.Format; import java.util.Map; import com.vaadin.data.Property; @@ -35,12 +34,6 @@ public class RichTextArea extends AbstractField<String> implements Vaadin6Component { /** - * Value formatter used to format the string contents. - */ - @Deprecated - private Format format; - - /** * Null representation. */ private String nullRepresentation = "null"; @@ -123,7 +116,7 @@ public class RichTextArea extends AbstractField<String> implements } // Adds the content as variable - String value = getFormattedValue(); + String value = getValue(); if (value == null) { value = getNullRepresentation(); } @@ -167,37 +160,6 @@ public class RichTextArea extends AbstractField<String> implements requestRepaint(); } - /** - * Gets the formatted string value. Sets the field value by using the - * assigned Format. - * - * @return the Formatted value. - * @see #setFormat(Format) - * @see Format - * @deprecated - */ - @Deprecated - protected String getFormattedValue() { - Object v = getValue(); - if (v == null) { - return null; - } - return v.toString(); - } - - @Override - public String getValue() { - String v = super.getValue(); - if (format == null || v == null) { - return v; - } - try { - return format.format(v); - } catch (final IllegalArgumentException e) { - return v; - } - } - @Override public void changeVariables(Object source, Map<String, Object> variables) { // Sets the text @@ -207,7 +169,7 @@ public class RichTextArea extends AbstractField<String> implements // has been updated String newValue = (String) variables.get("text"); - final String oldValue = getFormattedValue(); + final String oldValue = getValue(); if (newValue != null && (oldValue == null || isNullSettingAllowed()) && newValue.equals(getNullRepresentation())) { @@ -218,9 +180,9 @@ public class RichTextArea extends AbstractField<String> implements boolean wasModified = isModified(); setValue(newValue, true); - // If the modified status changes, or if we have a formatter, + // If the modified status changes, // repaint is needed after all. - if (format != null || wasModified != isModified()) { + if (wasModified != isModified()) { requestRepaint(); } } @@ -323,31 +285,6 @@ public class RichTextArea extends AbstractField<String> implements this.nullSettingAllowed = nullSettingAllowed; } - /** - * Gets the value formatter of TextField. - * - * @return the Format used to format the value. - * @deprecated replaced by {@link com.vaadin.data.util.PropertyFormatter} - */ - @Deprecated - public Format getFormat() { - return format; - } - - /** - * Gets the value formatter of TextField. - * - * @param format - * the Format used to format the value. Null disables the - * formatting. - * @deprecated replaced by {@link com.vaadin.data.util.PropertyFormatter} - */ - @Deprecated - public void setFormat(Format format) { - this.format = format; - requestRepaint(); - } - @Override protected boolean isEmpty() { return super.isEmpty() || getValue().length() == 0; |