]> source.dussan.org Git - vaadin-framework.git/commitdiff
Button now changes child element stylenames when primary style name is changed specif...
authorJohn Ahlroos <john@vaadin.com>
Tue, 2 Oct 2012 05:54:05 +0000 (08:54 +0300)
committerJohn Ahlroos <john@vaadin.com>
Tue, 2 Oct 2012 05:54:05 +0000 (08:54 +0300)
client/src/com/vaadin/client/ui/button/VButton.java

index 248687685633315ddae44e8d955d4ce57c70abe7..52987b01c197062cd766cb006839503478e267ac 100644 (file)
@@ -115,6 +115,13 @@ public class VButton extends FocusWidget implements ClickHandler {
         captionElement.setClassName(getStylePrimaryName() + "-caption");
     }
 
+    @Override
+    public void setStylePrimaryName(String style) {
+        super.setStylePrimaryName(style);
+        wrapper.setClassName(getStylePrimaryName() + "-wrap");
+        captionElement.setClassName(getStylePrimaryName() + "-caption");
+    }
+
     public void setText(String text) {
         captionElement.setInnerText(text);
     }