diff options
10 files changed, 74 insertions, 27 deletions
diff --git a/all/src/main/templates/release-notes.html b/all/src/main/templates/release-notes.html index 1160582ff6..7a5c5437be 100644 --- a/all/src/main/templates/release-notes.html +++ b/all/src/main/templates/release-notes.html @@ -117,6 +117,7 @@ <li>The way we handle GWT dependencies has been completely changed. See <a href="#gwtdep">this section</a> for more details.</li> <li>Client side compilation with Maven is now in strict mode by default, failing the compilation on any errors.</li> <li>Client side classes extending either AbstractGridMouseEvent or AbstractGridKeyEvent must now override the method getAssociatedType.</li> + <li>Changes to AbstractComponentState and TabState can potentially break compatibility for compiled add-ons.</li> </ul> <h3 id="knownissues">Known Issues and Limitations</h3> <ul> diff --git a/client/src/main/java/com/vaadin/client/StyleConstants.java b/client/src/main/java/com/vaadin/client/StyleConstants.java index 61ee4327a4..c88d7b733c 100644 --- a/client/src/main/java/com/vaadin/client/StyleConstants.java +++ b/client/src/main/java/com/vaadin/client/StyleConstants.java @@ -47,6 +47,8 @@ public class StyleConstants { /** * Style name and style name prefix for the error indicator element. + * + * @since 7.7.11 */ public static final String STYLE_NAME_ERROR_INDICATOR = "v-errorindicator"; } diff --git a/client/src/main/java/com/vaadin/client/TooltipInfo.java b/client/src/main/java/com/vaadin/client/TooltipInfo.java index b264f930ad..279b3b7686 100644 --- a/client/src/main/java/com/vaadin/client/TooltipInfo.java +++ b/client/src/main/java/com/vaadin/client/TooltipInfo.java @@ -45,7 +45,7 @@ public class TooltipInfo { * Constructs a new tooltip info instance. * * @param tooltip - * tooltip title + * tooltip title */ public TooltipInfo(String tooltip) { setTitle(tooltip); @@ -55,9 +55,9 @@ public class TooltipInfo { * Constructs a new tooltip info instance. * * @param tooltip - * tooltip title + * tooltip title * @param errorMessage - * error message + * error message */ public TooltipInfo(String tooltip, String errorMessage) { this(tooltip, errorMessage, null); @@ -67,11 +67,11 @@ public class TooltipInfo { * Constructs a new tooltip info instance. * * @param tooltip - * tooltip title + * tooltip title * @param errorMessage - * error message + * error message * @param identifier - * the tooltip's identifier + * the tooltip's identifier */ public TooltipInfo(String tooltip, String errorMessage, Object identifier) { this(tooltip, errorMessage, identifier, null); @@ -81,13 +81,15 @@ public class TooltipInfo { * Constructs a new tooltip info instance. * * @param tooltip - * tooltip title + * tooltip title * @param errorMessage - * error message + * error message * @param identifier - * the tooltip's identifier + * the tooltip's identifier * @param errorLevel - * error level + * error level + * + * @since 7.7.11 */ public TooltipInfo(String tooltip, String errorMessage, Object identifier, ErrorLevel errorLevel) { @@ -101,7 +103,7 @@ public class TooltipInfo { * Sets the tooltip's identifier. * * @param identifier - * the identifier to set + * the identifier to set */ public void setIdentifier(Object identifier) { this.identifier = identifier; @@ -129,7 +131,7 @@ public class TooltipInfo { * Sets the tooltip title. * * @param title - * the title to set + * the title to set */ public void setTitle(String title) { this.title = title; @@ -148,7 +150,7 @@ public class TooltipInfo { * Sets the error message. * * @param errorMessage - * the error message to set + * the error message to set */ public void setErrorMessage(String errorMessage) { errorMessageHtml = errorMessage; @@ -158,6 +160,7 @@ public class TooltipInfo { * Gets the error level. * * @return the error level + * @since 7.7.11 */ public ErrorLevel getErrorLevel() { return errorLevel; @@ -167,7 +170,8 @@ public class TooltipInfo { * Sets the error level. * * @param errorLevel - * the error level to set + * the error level to set + * @since 7.7.11 */ public void setErrorLevel(ErrorLevel errorLevel) { this.errorLevel = errorLevel; @@ -190,7 +194,7 @@ public class TooltipInfo { * identifier are equal. * * @param other - * the reference tooltip info instance with which to compare + * the reference tooltip info instance with which to compare * @return {@code true} if the instances are equal, {@code false} otherwise */ public boolean equals(TooltipInfo other) { diff --git a/client/src/main/java/com/vaadin/client/VCaption.java b/client/src/main/java/com/vaadin/client/VCaption.java index 7268e68e2a..b1df49d17e 100644 --- a/client/src/main/java/com/vaadin/client/VCaption.java +++ b/client/src/main/java/com/vaadin/client/VCaption.java @@ -335,6 +335,28 @@ public class VCaption extends HTML { } @Deprecated + /** + * Updates the caption without an owner component, for example a tabsheet's + * tab's. + * + * @param caption + * the caption text to set + * @param disabled + * style the caption as disabled if this is true + * @param hasDescription + * add description style if this is true + * @param hasError + * if true, add error indicator element + * @param errorLevel + * if hasError is true, use this value to define the severity + * @param iconURL + * url of the icon of the caption + * @param iconAltText + * alt text of the caption + * @return true if the caption was placed after the component when it wasn't + * before or vice versa + * @since 7.7.11 + */ public boolean updateCaptionWithoutOwner(String caption, boolean disabled, boolean hasDescription, boolean hasError, ErrorLevel errorLevel, String iconURL, String iconAltText) { diff --git a/client/src/main/java/com/vaadin/client/WidgetUtil.java b/client/src/main/java/com/vaadin/client/WidgetUtil.java index f256fc53f2..706cc6fb95 100644 --- a/client/src/main/java/com/vaadin/client/WidgetUtil.java +++ b/client/src/main/java/com/vaadin/client/WidgetUtil.java @@ -694,7 +694,7 @@ public class WidgetUtil { return @com.vaadin.client.WidgetUtil::getRequiredHeightBoundingClientRectDouble(Lcom/google/gwt/dom/client/Element;)(element); } var height = parseFloat(heightPx); // Will automatically skip "px" suffix - var border = parseFloat(cs.borderTopWidth) + parseFloat(cs.borderBottomWidth); // Will automatically skip "px" suffix + var border = parseFloat(cs.borderTopWidth) + parseFloat(cs.borderBottomWidth); // Will automatically skip "px" suffix var padding = parseFloat(cs.paddingTop) + parseFloat(cs.paddingBottom); // Will automatically skip "px" suffix return height+border+padding; }-*/; @@ -1883,6 +1883,8 @@ public class WidgetUtil { /** * Utility methods for displaying error message on components. + * + * @since 7.7.11 */ public static class ErrorUtil { @@ -1892,17 +1894,17 @@ public class WidgetUtil { * {@code prefix-errorLevel} format. * * @param element - * element to apply the style name to + * element to apply the style name to * @param prefix - * part of the style name before the error level string + * part of the style name before the error level string * @param errorLevel - * error level for which the style will be applied + * error level for which the style will be applied */ public static void setErrorLevelStyle(Element element, String prefix, ErrorLevel errorLevel) { for (ErrorLevel errorLevelValue : ErrorLevel.values()) { - String className = - prefix + "-" + errorLevelValue.toString().toLowerCase(); + String className = prefix + "-" + + errorLevelValue.toString().toLowerCase(); if (errorLevel == errorLevelValue) { element.addClassName(className); } else { diff --git a/client/src/main/java/com/vaadin/client/ui/orderedlayout/Slot.java b/client/src/main/java/com/vaadin/client/ui/orderedlayout/Slot.java index e7654091da..d182fbda39 100644 --- a/client/src/main/java/com/vaadin/client/ui/orderedlayout/Slot.java +++ b/client/src/main/java/com/vaadin/client/ui/orderedlayout/Slot.java @@ -547,6 +547,7 @@ public class Slot extends SimplePanel { * @param captionAsHtml * true if the caption should be rendered as HTML, false * otherwise + * @since 7.7.11 */ public void setCaption(String captionText, Icon icon, List<String> styles, String error, ErrorLevel errorLevel, boolean showError, diff --git a/server/src/main/java/com/vaadin/server/ErrorMessage.java b/server/src/main/java/com/vaadin/server/ErrorMessage.java index 6107d5ab5b..b54c92dead 100644 --- a/server/src/main/java/com/vaadin/server/ErrorMessage.java +++ b/server/src/main/java/com/vaadin/server/ErrorMessage.java @@ -84,6 +84,7 @@ public interface ErrorMessage extends Serializable { * Converts this to an error level that can be used on the client side. * * @return error level for the client side + * @since 7.7.11 */ public com.vaadin.shared.ui.ErrorLevel convertToShared() { switch (this) { @@ -103,32 +104,32 @@ public interface ErrorMessage extends Serializable { } /** - * @deprecated As of 7.0, use {@link ErrorLevel#SYSTEMERROR} instead + * @deprecated As of 7.0, use {@link ErrorLevel#SYSTEMERROR} instead */ @Deprecated public static final ErrorLevel SYSTEMERROR = ErrorLevel.SYSTEMERROR; /** - * @deprecated As of 7.0, use {@link ErrorLevel#CRITICAL} instead + * @deprecated As of 7.0, use {@link ErrorLevel#CRITICAL} instead */ @Deprecated public static final ErrorLevel CRITICAL = ErrorLevel.CRITICAL; /** - * @deprecated As of 7.0, use {@link ErrorLevel#ERROR} instead + * @deprecated As of 7.0, use {@link ErrorLevel#ERROR} instead */ @Deprecated public static final ErrorLevel ERROR = ErrorLevel.ERROR; /** - * @deprecated As of 7.0, use {@link ErrorLevel#WARNING} instead + * @deprecated As of 7.0, use {@link ErrorLevel#WARNING} instead */ @Deprecated public static final ErrorLevel WARNING = ErrorLevel.WARNING; /** - * @deprecated As of 7.0, use {@link ErrorLevel#INFORMATION} instead + * @deprecated As of 7.0, use {@link ErrorLevel#INFORMATION} instead */ @Deprecated public static final ErrorLevel INFORMATION = ErrorLevel.INFORMATION; diff --git a/shared/src/main/java/com/vaadin/shared/AbstractComponentState.java b/shared/src/main/java/com/vaadin/shared/AbstractComponentState.java index 8bbcc3eb15..542582fcdc 100644 --- a/shared/src/main/java/com/vaadin/shared/AbstractComponentState.java +++ b/shared/src/main/java/com/vaadin/shared/AbstractComponentState.java @@ -47,7 +47,11 @@ public class AbstractComponentState extends SharedState { /** HTML formatted error message for the component */ public String errorMessage = null; - /** Level of error */ + /** + * Level of error + * + * @since 7.7.11 + */ public ErrorLevel errorLevel = null; public boolean captionAsHtml = false; diff --git a/shared/src/main/java/com/vaadin/shared/ApplicationConstants.java b/shared/src/main/java/com/vaadin/shared/ApplicationConstants.java index 2a2d4c8ccb..68bade729c 100644 --- a/shared/src/main/java/com/vaadin/shared/ApplicationConstants.java +++ b/shared/src/main/java/com/vaadin/shared/ApplicationConstants.java @@ -49,6 +49,11 @@ public class ApplicationConstants implements Serializable { public static final String UIDL_SECURITY_TOKEN_ID = "Vaadin-Security-Key"; + /** + * Name for push connection identifier. + * + * @since 7.7.11 + */ public static final String UIDL_PUSH_ID = "Vaadin-Push-ID"; @Deprecated diff --git a/shared/src/main/java/com/vaadin/shared/ui/tabsheet/TabState.java b/shared/src/main/java/com/vaadin/shared/ui/tabsheet/TabState.java index c9e18508f7..92aeb07b28 100644 --- a/shared/src/main/java/com/vaadin/shared/ui/tabsheet/TabState.java +++ b/shared/src/main/java/com/vaadin/shared/ui/tabsheet/TabState.java @@ -35,6 +35,11 @@ public class TabState implements Serializable { public String styleName; public String key; public String componentError; + /** + * The error level of the component. + * + * @since 7.7.11 + */ public ErrorLevel componentErrorLevel; public String id; public String iconAltText; |