summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorAutomerge <automerge@vaadin.com>2012-04-18 13:21:32 +0000
committerAutomerge <automerge@vaadin.com>2012-04-18 13:21:32 +0000
commit1a95d50942f64bec70647587408f37d34addb767 (patch)
tree28b46ed243e5eb9e0dc8c52a1cce6f6cc71ebd44 /tests
parent9a695b7c8ca1b6c5bdc9d29f9088e694a895420d (diff)
downloadvaadin-framework-1a95d50942f64bec70647587408f37d34addb767.tar.gz
vaadin-framework-1a95d50942f64bec70647587408f37d34addb767.zip
[merge from 6.7] enhanced test case
svn changeset:23575/svn branch:6.8
Diffstat (limited to 'tests')
-rw-r--r--tests/testbench/com/vaadin/tests/components/TouchScrollables.java20
1 files changed, 19 insertions, 1 deletions
diff --git a/tests/testbench/com/vaadin/tests/components/TouchScrollables.java b/tests/testbench/com/vaadin/tests/components/TouchScrollables.java
index 39e5bb02c4..8d3ef715cc 100644
--- a/tests/testbench/com/vaadin/tests/components/TouchScrollables.java
+++ b/tests/testbench/com/vaadin/tests/components/TouchScrollables.java
@@ -4,6 +4,8 @@ import java.util.Collection;
import com.vaadin.data.Item;
import com.vaadin.data.util.IndexedContainer;
+import com.vaadin.event.Action;
+import com.vaadin.event.Action.Handler;
import com.vaadin.event.DataBoundTransferable;
import com.vaadin.event.dd.DragAndDropEvent;
import com.vaadin.event.dd.DropHandler;
@@ -108,12 +110,28 @@ public class TouchScrollables extends TestBase {
private void addDDSortableTable() {
final Table table;
table = new Table();
- table.setCaption("DD sortable table");
+ table.setCaption("DD sortable table with context menus");
// table.setWidth("100%");
table.setPageLength(10);
table.setRowHeaderMode(Table.ROW_HEADER_MODE_ID);
table.setSelectable(true);
table.setMultiSelect(true);
+
+ table.addActionHandler(new Handler() {
+
+ Action[] actions = new Action[] { new Action("FOO"),
+ new Action("BAR"), new Action("CAR") };
+
+ public Action[] getActions(Object target, Object sender) {
+ return actions;
+ }
+
+ public void handleAction(Action action, Object sender, Object target) {
+ getLayout().getWindow().showNotification(action.getCaption());
+
+ }
+ });
+
populateTable(table);
/*