aboutsummaryrefslogtreecommitdiffstats
path: root/src/com/vaadin/demo/sampler/ModeSwitch.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/vaadin/demo/sampler/ModeSwitch.java')
-rw-r--r--src/com/vaadin/demo/sampler/ModeSwitch.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/com/vaadin/demo/sampler/ModeSwitch.java b/src/com/vaadin/demo/sampler/ModeSwitch.java
index c6565c0c61..738f9f07cb 100644
--- a/src/com/vaadin/demo/sampler/ModeSwitch.java
+++ b/src/com/vaadin/demo/sampler/ModeSwitch.java
@@ -72,10 +72,11 @@ public class ModeSwitch extends CustomComponent {
updateStyles();
}
+ @SuppressWarnings("unchecked")
private void updateStyles() {
boolean first = true;
- for (Iterator it = layout.getComponentIterator(); it.hasNext();) {
- Button b = (Button) it.next();
+ for (Iterator<Button> it = layout.getComponentIterator(); it.hasNext();) {
+ Button b = it.next();
String isOn = (b.getData() == mode ? "-on" : "");
if (first) {
first = false;