diff options
author | John Ahlroos <john@vaadin.com> | 2012-09-05 16:03:53 +0300 |
---|---|---|
committer | John Ahlroos <john@vaadin.com> | 2012-09-05 16:03:53 +0300 |
commit | 223fc1421dea2e1fd6c80ce4b859c17ca0a428e9 (patch) | |
tree | d597efcacbedde49cf5205d67038a3f75b92043b | |
parent | 7671871725ce03c356de17ad4ce58a7bfba0f7d6 (diff) | |
download | vaadin-framework-223fc1421dea2e1fd6c80ce4b859c17ca0a428e9.tar.gz vaadin-framework-223fc1421dea2e1fd6c80ce4b859c17ca0a428e9.zip |
Removed duplicate method toggleStyleName (replaced by
setStyleName(String,Boolean) )
-rw-r--r-- | client/src/com/vaadin/client/ui/orderedlayout/VBoxLayout.java | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/client/src/com/vaadin/client/ui/orderedlayout/VBoxLayout.java b/client/src/com/vaadin/client/ui/orderedlayout/VBoxLayout.java index e04ef93444..4df4ce6524 100644 --- a/client/src/com/vaadin/client/ui/orderedlayout/VBoxLayout.java +++ b/client/src/com/vaadin/client/ui/orderedlayout/VBoxLayout.java @@ -541,19 +541,11 @@ public class VBoxLayout extends FlowPanel { } } - private void toggleStyleName(String name, boolean enabled) { - if (enabled) { - addStyleName(name); - } else { - removeStyleName(name); - } - } - void setMargin(MarginInfo marginInfo) { - toggleStyleName("v-margin-top", marginInfo.hasTop()); - toggleStyleName("v-margin-right", marginInfo.hasRight()); - toggleStyleName("v-margin-bottom", marginInfo.hasBottom()); - toggleStyleName("v-margin-left", marginInfo.hasLeft()); + setStyleName("v-margin-top", marginInfo.hasTop()); + setStyleName("v-margin-right", marginInfo.hasRight()); + setStyleName("v-margin-bottom", marginInfo.hasBottom()); + setStyleName("v-margin-left", marginInfo.hasLeft()); } protected void setSpacing(boolean spacingEnabled) { |