aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/com/itmill/toolkit/terminal/gwt/client/Caption.java7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/com/itmill/toolkit/terminal/gwt/client/Caption.java b/src/com/itmill/toolkit/terminal/gwt/client/Caption.java
index f5ba082f73..06d502696f 100644
--- a/src/com/itmill/toolkit/terminal/gwt/client/Caption.java
+++ b/src/com/itmill/toolkit/terminal/gwt/client/Caption.java
@@ -46,9 +46,6 @@ public class Caption extends HTML {
DOM.setElementProperty(errorIndicatorElement, "className",
"i-errorindicator");
DOM.insertChild(getElement(), errorIndicatorElement, 0);
- } else {
- // Restore the indicator that was previously made invisible
- DOM.setStyleAttribute(errorIndicatorElement, "display", "inline");
}
if (errorMessage == null) {
errorMessage = new ErrorMessage();
@@ -56,8 +53,8 @@ public class Caption extends HTML {
errorMessage.updateFromUIDL(errorUidl);
} else if (errorIndicatorElement != null) {
- // Just make the error indicator element invisible
- DOM.setStyleAttribute(errorIndicatorElement, "display", "none");
+ DOM.removeChild(getElement(), errorIndicatorElement);
+ errorIndicatorElement = null;
}
if (uidl.hasAttribute("icon")) {