From 5ab84abfd50d4aa2b142687661f9288d51a6440a Mon Sep 17 00:00:00 2001 From: Artur Signell Date: Tue, 6 Nov 2012 18:21:04 +0200 Subject: Added Component.getDescription (#8154) Change-Id: Iaa2f35415e68ecd4d53fd8743eb2c5cfb0afd36a --- server/src/com/vaadin/ui/AbstractComponent.java | 59 ++----------------------- server/src/com/vaadin/ui/Component.java | 59 +++++++++++++++++++++++++ 2 files changed, 63 insertions(+), 55 deletions(-) (limited to 'server/src/com') diff --git a/server/src/com/vaadin/ui/AbstractComponent.java b/server/src/com/vaadin/ui/AbstractComponent.java index 4a3aba3cf4..fb550fa944 100644 --- a/server/src/com/vaadin/ui/AbstractComponent.java +++ b/server/src/com/vaadin/ui/AbstractComponent.java @@ -421,63 +421,12 @@ public abstract class AbstractComponent extends AbstractClientConnector } } - /** - *

- * Gets the component's description, used in tooltips and can be displayed - * directly in certain other components such as forms. The description can - * be used to briefly describe the state of the component to the user. The - * description string may contain certain XML tags: - *

- * - *

- * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - *
TagDescriptionExample
<b>boldbold text
<i>italicitalic text
<u>underlinedunderlined text
<br>linebreakN/A
<ul>
- * <li>item1
- * <li>item1
- * </ul>
item list - *
    - *
  • item1 - *
  • item2 - *
- *
- *

- * - *

- * These tags may be nested. - *

+ /* + * (non-Javadoc) * - * @return component's description String + * @see com.vaadin.ui.Component#getDescription() */ + @Override public String getDescription() { return getState().description; } diff --git a/server/src/com/vaadin/ui/Component.java b/server/src/com/vaadin/ui/Component.java index 186aaa0219..36868c41e9 100644 --- a/server/src/com/vaadin/ui/Component.java +++ b/server/src/com/vaadin/ui/Component.java @@ -646,6 +646,65 @@ public interface Component extends ClientConnector, Sizeable, Serializable { */ public String getId(); + /** + *

+ * Gets the component's description, used in tooltips and can be displayed + * directly in certain other components such as forms. The description can + * be used to briefly describe the state of the component to the user. The + * description string may contain certain XML tags: + *

+ * + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
TagDescriptionExample
<b>boldbold text
<i>italicitalic text
<u>underlinedunderlined text
<br>linebreakN/A
<ul>
+ * <li>item1
+ * <li>item1
+ * </ul>
item list + *
    + *
  • item1 + *
  • item2 + *
+ *
+ *

+ * + *

+ * These tags may be nested. + *

+ * + * @return component's description String + */ + public String getDescription(); + /* Component event framework */ /** -- cgit v1.2.3