Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add form container

  • Loading branch information...
commit 6de1903e26c0c68a08ff7a5454d0ce5925758b9b 1 parent a4ad683
@hpehl hpehl authored
Showing with 69 additions and 27 deletions.
  1. +1 −1  diagnostics/src/main/java/com/google/gwt/debugpanel/client/DelayedDebugPanelComponent.java
  2. +2 −2 diagnostics/src/main/java/com/google/gwt/debugpanel/widgets/DebugPanelWidget.java
  3. +2 −2 diagnostics/src/main/java/com/google/gwt/debugpanel/widgets/TreeTable.java
  4. +2 −2 gui/src/main/java/org/jboss/as/console/client/core/DisposableView.java
  5. +2 −2 gui/src/main/java/org/jboss/as/console/client/core/SuspendableView.java
  6. +1 −1  gui/src/main/java/org/jboss/as/console/client/shared/deployment/DeploymentStep1.java
  7. +1 −1  gui/src/main/java/org/jboss/as/console/client/shared/viewframework/AbstractEntityView.java
  8. +1 −1  gui/src/main/java/org/jboss/as/console/client/shared/viewframework/TabbedFormLayoutPanel.java
  9. +40 −0 gui/src/main/java/org/jboss/mbui/client/aui/as7/Form.java
  10. +1 −1  gui/src/main/java/org/jboss/mbui/client/aui/mapping/{ → as7}/ResourceAttribute.java
  11. +3 −1 gui/src/main/java/org/jboss/mbui/client/aui/mapping/{ → as7}/ResourceMapping.java
  12. +4 −5 ...src/main/java/org/jboss/mbui/client/cui/workbench/reification/{InputStrategy.java → FormStrategy.java}
  13. +1 −1  gui/src/main/java/org/jboss/mbui/client/cui/workbench/reification/Reificator.java
  14. +2 −2 gui/src/main/java/org/jboss/mbui/client/cui/workbench/reification/SelectStrategy.java
  15. +5 −5 gui/src/main/java/org/jboss/mbui/client/cui/workbench/repository/DataSourceSample.java
  16. +1 −0  gui/src/test/java/org/jboss/mbui/client/aui/mapping/ResourceMappingTest.java
View
2  diagnostics/src/main/java/com/google/gwt/debugpanel/client/DelayedDebugPanelComponent.java
@@ -20,7 +20,7 @@
import com.google.gwt.user.client.ui.Widget;
/**
- * A {@link DebugPanelWidget.Component} that has the widget initialization
+ * A {@link DebugPanelWidget.Component} that has the widgets initialization
* delayed until first shown.
*/
public abstract class DelayedDebugPanelComponent
View
4 diagnostics/src/main/java/com/google/gwt/debugpanel/widgets/DebugPanelWidget.java
@@ -89,8 +89,8 @@ public void reset() {
public boolean isVisibleOnStartup();
/**
- * Construct the widget to be shown when called. Note, this will only be
- * called once, so the widget creation can be easily delayed until called.
+ * Construct the widgets to be shown when called. Note, this will only be
+ * called once, so the widgets creation can be easily delayed until called.
*/
public Widget getWidget();
}
View
4 diagnostics/src/main/java/com/google/gwt/debugpanel/widgets/TreeTable.java
@@ -33,7 +33,7 @@
import java.util.Map;
/**
- * A widget displaying a {@link TreeTableModel}. This will display a table,
+ * A widgets displaying a {@link TreeTableModel}. This will display a table,
* where the first column is a tree and each node in the tree is a table row.
*/
public class TreeTable extends Composite {
@@ -402,7 +402,7 @@ public ItemWidget getWidget() {
}
/**
- * The widget displayed in the first column containing the label and tree image.
+ * The widgets displayed in the first column containing the label and tree image.
*/
public static class ItemWidget extends Widget {
protected final Element image;
View
4 gui/src/main/java/org/jboss/as/console/client/core/DisposableView.java
@@ -23,7 +23,7 @@
import com.gwtplatform.mvp.client.View;
/**
- * A disposable view will create a widget instance every time
+ * A disposable view will create a widgets instance every time
* the view is going to be revealed.
*
* @see SuspendableView
@@ -36,7 +36,7 @@
/**
* Called when the view is going to be revealed.
*
- * @return a widget instance
+ * @return a widgets instance
*/
Widget createWidget();
}
View
4 gui/src/main/java/org/jboss/as/console/client/core/SuspendableView.java
@@ -23,7 +23,7 @@
import com.gwtplatform.mvp.client.View;
/**
- * A suspendable view retains a specific widget instance
+ * A suspendable view retains a specific widgets instance
* when the view is hidden and notify the view through {@link #onResume()}
* when it's going to be revealed again.
*
@@ -35,7 +35,7 @@
public interface SuspendableView extends View {
/**
- * Called upon first creation of the widget
+ * Called upon first creation of the widgets
* @return
*/
Widget createWidget();
View
2  gui/src/main/java/org/jboss/as/console/client/shared/deployment/DeploymentStep1.java
@@ -90,7 +90,7 @@ public Widget asWidget()
panel.getElement().setAttribute("style", "width:100%");
form.setWidget(panel);
- // Create a FileUpload widget.
+ // Create a FileUpload widgets.
final FileUpload upload = new FileUpload();
upload.setName("uploadFormElement");
panel.add(upload);
View
2  gui/src/main/java/org/jboss/as/console/client/shared/viewframework/AbstractEntityView.java
@@ -172,7 +172,7 @@ public Widget createWidget() {
}
/**
- * Creates a default widget without the top most tab.
+ * Creates a default widgets without the top most tab.
* It can be easily embedded into a TablayoutPanel for instance.
*
* @return
View
2  ...src/main/java/org/jboss/as/console/client/shared/viewframework/TabbedFormLayoutPanel.java
@@ -115,7 +115,7 @@ public void onDelete(T entity) {
layout.add(toolStrip.asWidget());
- // help widget
+ // help widgets
if (address != null) {
layout.add(HelpWidgetFactory.makeHelpWidget(address, form));
}
View
40 gui/src/main/java/org/jboss/mbui/client/aui/as7/Form.java
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2011 Red Hat Inc. and/or its affiliates and other contributors
+ * as indicated by the @author tags. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.mbui.client.aui.as7;
+
+import org.jboss.mbui.client.aui.aim.Container;
+
+import static org.jboss.mbui.client.aui.aim.TemporalOperator.OrderIndependance;
+
+/**
+ * @author Harald Pehl
+ * @date 11/12/2012
+ */
+public class Form extends Container
+{
+ public Form(final String id)
+ {
+ super(id, OrderIndependance);
+ }
+
+ public Form(final String id, final String name)
+ {
+ super(id, name, OrderIndependance);
+ }
+}
View
2  ...client/aui/mapping/ResourceAttribute.java → ...nt/aui/mapping/as7/ResourceAttribute.java
@@ -16,7 +16,7 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
* MA 02110-1301, USA.
*/
-package org.jboss.mbui.client.aui.mapping;
+package org.jboss.mbui.client.aui.mapping.as7;
/**
* @author Harald Pehl
View
4 ...i/client/aui/mapping/ResourceMapping.java → ...ient/aui/mapping/as7/ResourceMapping.java
@@ -16,7 +16,9 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
* MA 02110-1301, USA.
*/
-package org.jboss.mbui.client.aui.mapping;
+package org.jboss.mbui.client.aui.mapping.as7;
+
+import org.jboss.mbui.client.aui.mapping.Mapping;
import java.util.ArrayList;
import java.util.List;
View
9 .../workbench/reification/InputStrategy.java → ...i/workbench/reification/FormStrategy.java
@@ -22,10 +22,9 @@
import org.jboss.ballroom.client.widgets.forms.Form;
import org.jboss.ballroom.client.widgets.forms.FormItem;
import org.jboss.ballroom.client.widgets.forms.TextItem;
-import org.jboss.mbui.client.aui.aim.Input;
import org.jboss.mbui.client.aui.aim.InteractionUnit;
-import org.jboss.mbui.client.aui.mapping.ResourceAttribute;
-import org.jboss.mbui.client.aui.mapping.ResourceMapping;
+import org.jboss.mbui.client.aui.mapping.as7.ResourceAttribute;
+import org.jboss.mbui.client.aui.mapping.as7.ResourceMapping;
import org.jboss.mbui.client.cui.Context;
import org.jboss.mbui.client.cui.ReificationStrategy;
@@ -36,7 +35,7 @@
* @author Harald Pehl
* @date 11/01/2012
*/
-public class InputStrategy implements ReificationStrategy<ReificationWidget>
+public class FormStrategy implements ReificationStrategy<ReificationWidget>
{
@Override
public ReificationWidget reify(final InteractionUnit interactionUnit, final Context context)
@@ -52,7 +51,7 @@ public ReificationWidget reify(final InteractionUnit interactionUnit, final Cont
@Override
public boolean appliesTo(final InteractionUnit interactionUnit)
{
- return interactionUnit instanceof Input;
+ return interactionUnit instanceof org.jboss.mbui.client.aui.as7.Form;
}
View
2  gui/src/main/java/org/jboss/mbui/client/cui/workbench/reification/Reificator.java
@@ -40,7 +40,7 @@ public Reificator()
this.strategies.add(new OrderIndependanceStrategy());
this.strategies.add(new ChoiceStrategy());
this.strategies.add(new SelectStrategy());
- this.strategies.add(new InputStrategy());
+ this.strategies.add(new FormStrategy());
}
public ReificationWidget reify(final InteractionUnit interactionUnit, final Context context)
View
4 gui/src/main/java/org/jboss/mbui/client/cui/workbench/reification/SelectStrategy.java
@@ -27,8 +27,8 @@
import org.jboss.ballroom.client.widgets.tables.DefaultPager;
import org.jboss.mbui.client.aui.aim.InteractionUnit;
import org.jboss.mbui.client.aui.aim.Select;
-import org.jboss.mbui.client.aui.mapping.ResourceAttribute;
-import org.jboss.mbui.client.aui.mapping.ResourceMapping;
+import org.jboss.mbui.client.aui.mapping.as7.ResourceAttribute;
+import org.jboss.mbui.client.aui.mapping.as7.ResourceMapping;
import org.jboss.mbui.client.cui.Context;
import org.jboss.mbui.client.cui.ReificationStrategy;
View
10 gui/src/main/java/org/jboss/mbui/client/cui/workbench/repository/DataSourceSample.java
@@ -19,12 +19,12 @@
package org.jboss.mbui.client.cui.workbench.repository;
import org.jboss.mbui.client.aui.aim.Container;
-import org.jboss.mbui.client.aui.aim.Input;
import org.jboss.mbui.client.aui.aim.InteractionUnit;
import org.jboss.mbui.client.aui.aim.Select;
+import org.jboss.mbui.client.aui.as7.Form;
import org.jboss.mbui.client.aui.mapping.Mapping;
-import org.jboss.mbui.client.aui.mapping.ResourceAttribute;
-import org.jboss.mbui.client.aui.mapping.ResourceMapping;
+import org.jboss.mbui.client.aui.mapping.as7.ResourceAttribute;
+import org.jboss.mbui.client.aui.mapping.as7.ResourceMapping;
import static org.jboss.mbui.client.aui.aim.TemporalOperator.Choice;
import static org.jboss.mbui.client.aui.aim.TemporalOperator.OrderIndependance;
@@ -53,10 +53,10 @@ public InteractionUnit build()
Container forms = new Container("datasourceAttributes", "Datasource", Choice);
overview.add(forms);
- Input basicAttributes = new Input("basicAttributes", "Attributes");
+ Form basicAttributes = new Form("basicAttributes", "Attributes");
forms.add(basicAttributes);
- Input connectionAttributes = new Input("connectionAttributes", "Connection");
+ Form connectionAttributes = new Form("connectionAttributes", "Connection");
forms.add(connectionAttributes);
// mappings (required)
View
1  gui/src/test/java/org/jboss/mbui/client/aui/mapping/ResourceMappingTest.java
@@ -18,6 +18,7 @@
*/
package org.jboss.mbui.client.aui.mapping;
+import org.jboss.mbui.client.aui.mapping.as7.ResourceMapping;
import org.junit.Before;
import org.junit.Test;
Please sign in to comment.
Something went wrong with that request. Please try again.