Skip to content

Commit

Permalink
WW-5510 Marks support for tooltips as deprecated
Browse files Browse the repository at this point in the history
This will be removed in the minor release, migrate to use native html tooltip support
  • Loading branch information
lukaszlenart committed Jan 16, 2025
1 parent fa60e1c commit c2a5bfe
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
13 changes: 10 additions & 3 deletions core/src/main/java/org/apache/struts2/components/UIBean.java
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@
* <!-- END SNIPPET: javascriptRelatedAttributes -->
*
* <!-- START SNIPPET: tooltipattributes -->
*
* <strong>Deprecated since 7.0.1</strong
* <table border="1" summary="">
* <tr>
* <td>Attribute</td>
Expand Down Expand Up @@ -344,7 +344,7 @@
*
* <!-- START SNIPPET: tooltipdescription -->
* <p>
* <b>tooltipConfig is deprecated, use individual tooltip configuration attributes instead </b>
* <strong>tooltipConfig is deprecated, use individual tooltip configuration attributes instead </strong>
* </p>
*
* <p>
Expand Down Expand Up @@ -380,7 +380,7 @@
*
* <pre>
* <!-- START SNIPPET: tooltipexample -->
*
* <strong>Deprecated since 7.0.1</strong>
* &lt;!-- Example 1: --&gt;
* &lt;s:form
* tooltipDelay="500"
Expand Down Expand Up @@ -968,6 +968,7 @@ protected void enableAncestorFormCustomOnsubmit() {
}
}

@Deprecated(since = "7.0.1", forRemoval = true)
protected Map<String, String> getTooltipConfig(UIBean component) {
Object tooltipConfigObj = component.getAttributes().get("tooltipConfig");
Map<String, String> result = new LinkedHashMap<>();
Expand Down Expand Up @@ -1237,11 +1238,13 @@ public void setAccesskey(String accesskey) {
}

@StrutsTagAttribute(description="Set the tooltip of this particular component")
@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltip(String tooltip) {
this.tooltip = tooltip;
}

@StrutsTagAttribute(description="Deprecated. Use individual tooltip configuration attributes instead.")
@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltipConfig(String tooltipConfig) {
this.tooltipConfig = tooltipConfig;
}
Expand All @@ -1252,22 +1255,26 @@ public void setKey(String key) {
}

@StrutsTagAttribute(description="Use JavaScript to generate tooltips", type="Boolean", defaultValue="false")
@Deprecated(since = "7.0.1", forRemoval = true)
public void setJavascriptTooltip(String javascriptTooltip) {
this.javascriptTooltip = javascriptTooltip;
}

@StrutsTagAttribute(description="CSS class applied to JavaScrip tooltips", defaultValue="StrutsTTClassic")
@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltipCssClass(String tooltipCssClass) {
this.tooltipCssClass = tooltipCssClass;
}

@StrutsTagAttribute(description="Delay in milliseconds, before showing JavaScript tooltips ",
defaultValue="Classic")
@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltipDelay(String tooltipDelay) {
this.tooltipDelay = tooltipDelay;
}

@StrutsTagAttribute(description="Icon path used for image that will have the tooltip")
@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltipIconPath(String tooltipIconPath) {
this.tooltipIconPath = tooltipIconPath;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -261,10 +261,12 @@ public void setOnchange(String onchange) {
this.onchange = onchange;
}

@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltip(String tooltip) {
this.tooltip = tooltip;
}

@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltipConfig(String tooltipConfig) {
this.tooltipConfig = tooltipConfig;
}
Expand All @@ -277,18 +279,22 @@ public void setKey(String key) {
this.key = key;
}

@Deprecated(since = "7.0.1", forRemoval = true)
public void setJavascriptTooltip(String javascriptTooltip) {
this.javascriptTooltip = javascriptTooltip;
}

@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltipCssClass(String tooltipCssClass) {
this.tooltipCssClass = tooltipCssClass;
}

@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltipDelay(String tooltipDelay) {
this.tooltipDelay = tooltipDelay;
}

@Deprecated(since = "7.0.1", forRemoval = true)
public void setTooltipIconPath(String tooltipIconPath) {
this.tooltipIconPath = tooltipIconPath;
}
Expand Down

0 comments on commit c2a5bfe

Please sign in to comment.