From 499ca3bbe89afdd4150bb58091a7b858ff79c5fd Mon Sep 17 00:00:00 2001 From: Jens Jansson Date: Fri, 20 Jan 2012 11:05:43 +0200 Subject: #8019 Table's column alignment constants to enum. --- .../com/vaadin/tests/components/table/Tables.java | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'tests/testbench') diff --git a/tests/testbench/com/vaadin/tests/components/table/Tables.java b/tests/testbench/com/vaadin/tests/components/table/Tables.java index 2675479e36..7fae10b24e 100644 --- a/tests/testbench/com/vaadin/tests/components/table/Tables.java +++ b/tests/testbench/com/vaadin/tests/components/table/Tables.java @@ -15,6 +15,7 @@ import com.vaadin.ui.Button; import com.vaadin.ui.Label; import com.vaadin.ui.Label.ContentMode; import com.vaadin.ui.Table; +import com.vaadin.ui.Table.Align; import com.vaadin.ui.Table.CellStyleGenerator; import com.vaadin.ui.Table.ColumnGenerator; import com.vaadin.ui.Table.ColumnHeaderMode; @@ -43,9 +44,9 @@ public class Tables extends AbstractSelectTestCase } /* COMMANDS */ - private Command columnAlignmentCommand = new Command() { + private Command columnAlignmentCommand = new Command() { - public void execute(T c, String alignment, Object propertyId) { + public void execute(T c, Align alignment, Object propertyId) { c.setColumnAlignment(propertyId, alignment); } @@ -136,7 +137,7 @@ public class Tables extends AbstractSelectTestCase protected Command alignColumnLeftCommand = new Command() { public void execute(T c, Object propertyId, Object data) { - c.setColumnAlignment(propertyId, (String) data); + c.setColumnAlignment(propertyId, (Align) data); } }; @@ -603,10 +604,10 @@ public class Tables extends AbstractSelectTestCase createBooleanAction("Collapsed", category, false, columnCollapsed, propertyId); t.log("Collapsed"); - LinkedHashMap options = new LinkedHashMap(); - options.put("Left", Table.ALIGN_LEFT); - options.put("Center", Table.ALIGN_CENTER); - options.put("Right", Table.ALIGN_RIGHT); + LinkedHashMap options = new LinkedHashMap(); + options.put("Left", Align.LEFT); + options.put("Center", Align.CENTER); + options.put("Right", Align.RIGHT); createSelectAction("Alignment", category, options, "Left", columnAlignmentCommand, propertyId); -- cgit v1.2.3