Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(145)

Unified Diff: frontend/client/src/autotest/afe/TestSelectorDisplay.java

Issue 3554003: Merge remote branch 'cros/upstream' into tempbranch3 (Closed) Base URL: http://git.chromium.org/git/autotest.git
Patch Set: Created 10 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: frontend/client/src/autotest/afe/TestSelectorDisplay.java
diff --git a/frontend/client/src/autotest/afe/TestSelectorDisplay.java b/frontend/client/src/autotest/afe/TestSelectorDisplay.java
new file mode 100644
index 0000000000000000000000000000000000000000..19b6bf758e50f08e9be446a7a2f285c2b3156dcc
--- /dev/null
+++ b/frontend/client/src/autotest/afe/TestSelectorDisplay.java
@@ -0,0 +1,73 @@
+package autotest.afe;
+
+import autotest.afe.TestSelector.IDataTable;
+import autotest.afe.TestSelector.IDataTable.DataTableImpl;
+import autotest.afe.TestSelector.ISelectionManager;
+import autotest.afe.TestSelector.ISelectionManager.SelectionManagerImpl;
+import autotest.common.table.DataTable;
+import autotest.common.ui.ExtendedListBox;
+import autotest.common.ui.SimplifiedList;
+
+import com.google.gwt.user.client.ui.Composite;
+import com.google.gwt.user.client.ui.HTML;
+import com.google.gwt.user.client.ui.HasHTML;
+import com.google.gwt.user.client.ui.HorizontalPanel;
+import com.google.gwt.user.client.ui.HorizontalSplitPanel;
+import com.google.gwt.user.client.ui.Label;
+import com.google.gwt.user.client.ui.Panel;
+import com.google.gwt.user.client.ui.VerticalPanel;
+
+public class TestSelectorDisplay extends Composite implements TestSelector.Display {
+ private static final String[][] testTableColumns = new String[][] {
+ {DataTable.WIDGET_COLUMN, ""},
+ {"name", "Test"},
+ };
+
+ private ExtendedListBox testTypeSelect = new ExtendedListBox();
+ private DataTableImpl testTable = new DataTableImpl(testTableColumns);
+ private SelectionManagerImpl testSelection = new SelectionManagerImpl(testTable, false);
+ private HTML testInfo = new HTML("Click a test to view its description");
+ private HorizontalSplitPanel mainPanel = new HorizontalSplitPanel();
+
+ public TestSelectorDisplay() {
+ testInfo.setStyleName("test-description");
+
+ testTable.fillParent();
+ testTable.setClickable(true);
+
+ Panel testTypePanel = new HorizontalPanel();
+ testTypePanel.add(new Label("Test type:"));
+ testTypePanel.add(testTypeSelect);
+
+ Panel testInfoPanel = new VerticalPanel();
+ testInfoPanel.add(testInfo);
+
+ mainPanel.setLeftWidget(testTable);
+ mainPanel.setRightWidget(testInfoPanel);
+ mainPanel.setSize("100%", "30em");
+ mainPanel.setSplitPosition("20em");
+
+ Panel container = new VerticalPanel();
+ container.add(testTypePanel);
+ container.add(mainPanel);
+ container.setWidth("100%");
+
+ initWidget(container);
+ }
+
+ public SimplifiedList getTestTypeSelect() {
+ return testTypeSelect;
+ }
+
+ public HasHTML getTestInfo() {
+ return testInfo;
+ }
+
+ public ISelectionManager getTestSelection() {
+ return testSelection;
+ }
+
+ public IDataTable getTestTable() {
+ return testTable;
+ }
+}
« no previous file with comments | « frontend/client/src/autotest/afe/TestSelector.java ('k') | frontend/client/src/autotest/afe/UserPreferencesView.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698