click-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sa...@apache.org
Subject svn commit: r1052766 - in /click/trunk/click/examples/src/org/apache/click/examples/page/form: ExtraControlsForm.java FormLayout.java SearchForm.java StandardControlsForm.java dynamic/PopulateOnSelect.java
Date Sat, 25 Dec 2010 10:48:23 GMT
Author: sabob
Date: Sat Dec 25 10:48:23 2010
New Revision: 1052766

URL: http://svn.apache.org/viewvc?rev=1052766&view=rev
Log:
Remove auto binding from examples CLK-742

Modified:
    click/trunk/click/examples/src/org/apache/click/examples/page/form/ExtraControlsForm.java
    click/trunk/click/examples/src/org/apache/click/examples/page/form/FormLayout.java
    click/trunk/click/examples/src/org/apache/click/examples/page/form/SearchForm.java
    click/trunk/click/examples/src/org/apache/click/examples/page/form/StandardControlsForm.java
    click/trunk/click/examples/src/org/apache/click/examples/page/form/dynamic/PopulateOnSelect.java

Modified: click/trunk/click/examples/src/org/apache/click/examples/page/form/ExtraControlsForm.java
URL: http://svn.apache.org/viewvc/click/trunk/click/examples/src/org/apache/click/examples/page/form/ExtraControlsForm.java?rev=1052766&r1=1052765&r2=1052766&view=diff
==============================================================================
--- click/trunk/click/examples/src/org/apache/click/examples/page/form/ExtraControlsForm.java
(original)
+++ click/trunk/click/examples/src/org/apache/click/examples/page/form/ExtraControlsForm.java
Sat Dec 25 10:48:23 2010
@@ -47,7 +47,6 @@ import org.apache.click.extras.control.P
 import org.apache.click.extras.control.RegexField;
 import org.apache.click.extras.control.TelephoneField;
 import org.apache.click.extras.control.VirtualKeyboard;
-import org.apache.click.util.Bindable;
 import org.apache.click.util.ContainerUtils;
 import org.springframework.stereotype.Component;
 
@@ -66,8 +65,8 @@ public class ExtraControlsForm extends B
         boolean javaScriptValidate = false;
     }
 
-    @Bindable protected Form form = new Form();
-    @Bindable protected Form optionsForm = new Form();
+    private Form form = new Form("form");
+    private Form optionsForm = new Form("optionsForm");
 
     private CheckList checkList = new CheckList("checkList");
     private Checkbox allFieldsRequired = new Checkbox("allFieldsRequired");
@@ -79,6 +78,9 @@ public class ExtraControlsForm extends B
     // Constructor ------------------------------------------------------------
 
     public ExtraControlsForm() {
+        addControl(form);
+        addControl(optionsForm);
+
         form.setErrorsPosition(Form.POSITION_TOP);
         form.setColumns(2);
 

Modified: click/trunk/click/examples/src/org/apache/click/examples/page/form/FormLayout.java
URL: http://svn.apache.org/viewvc/click/trunk/click/examples/src/org/apache/click/examples/page/form/FormLayout.java?rev=1052766&r1=1052765&r2=1052766&view=diff
==============================================================================
--- click/trunk/click/examples/src/org/apache/click/examples/page/form/FormLayout.java (original)
+++ click/trunk/click/examples/src/org/apache/click/examples/page/form/FormLayout.java Sat
Dec 25 10:48:23 2010
@@ -30,7 +30,6 @@ import org.apache.click.examples.page.Ho
 import org.apache.click.extras.control.EmailField;
 import org.apache.click.extras.control.PageSubmit;
 import org.apache.click.extras.control.TelephoneField;
-import org.apache.click.util.Bindable;
 
 /**
  * Provides Form layout examples using the Form and FieldSet controls.
@@ -39,10 +38,13 @@ public class FormLayout extends BorderPa
 
     private static final long serialVersionUID = 1L;
 
-    @Bindable protected Form form1 = new Form();
-    @Bindable protected Form form2 = new Form();
+    private Form form1 = new Form("form1");
+    private Form form2 = new Form("form2");
 
     public FormLayout() {
+        addControl(form1);
+        addControl(form2);
+
         // ------
         // Form 1
         form1.setColumns(3);

Modified: click/trunk/click/examples/src/org/apache/click/examples/page/form/SearchForm.java
URL: http://svn.apache.org/viewvc/click/trunk/click/examples/src/org/apache/click/examples/page/form/SearchForm.java?rev=1052766&r1=1052765&r2=1052766&view=diff
==============================================================================
--- click/trunk/click/examples/src/org/apache/click/examples/page/form/SearchForm.java (original)
+++ click/trunk/click/examples/src/org/apache/click/examples/page/form/SearchForm.java Sat
Dec 25 10:48:23 2010
@@ -29,7 +29,6 @@ import org.apache.click.control.TextFiel
 import org.apache.click.examples.domain.Customer;
 import org.apache.click.examples.page.BorderPage;
 import org.apache.click.examples.service.CustomerService;
-import org.apache.click.util.Bindable;
 import org.apache.commons.lang.math.NumberUtils;
 import org.springframework.stereotype.Component;
 
@@ -42,7 +41,7 @@ public class SearchForm extends BorderPa
 
     private static final long serialVersionUID = 1L;
 
-    @Bindable protected Form form = new Form();
+    private Form form = new Form("form");
 
     private TextField textField;
     private Select typeSelect;
@@ -53,6 +52,8 @@ public class SearchForm extends BorderPa
     // Constructor ------------------------------------------------------------
 
     public SearchForm() {
+        addControl(form);
+
         textField = new TextField("search");
         form.add(textField);
 

Modified: click/trunk/click/examples/src/org/apache/click/examples/page/form/StandardControlsForm.java
URL: http://svn.apache.org/viewvc/click/trunk/click/examples/src/org/apache/click/examples/page/form/StandardControlsForm.java?rev=1052766&r1=1052765&r2=1052766&view=diff
==============================================================================
--- click/trunk/click/examples/src/org/apache/click/examples/page/form/StandardControlsForm.java
(original)
+++ click/trunk/click/examples/src/org/apache/click/examples/page/form/StandardControlsForm.java
Sat Dec 25 10:48:23 2010
@@ -46,7 +46,6 @@ import org.apache.click.examples.domain.
 import org.apache.click.examples.page.BorderPage;
 import org.apache.click.examples.service.CustomerService;
 import org.apache.click.examples.util.ExampleUtils;
-import org.apache.click.util.Bindable;
 import org.apache.click.util.ContainerUtils;
 import org.apache.click.dataprovider.DataProvider;
 import org.springframework.stereotype.Component;
@@ -66,8 +65,8 @@ public class StandardControlsForm extend
         boolean javaScriptValidate = false;
     }
 
-    @Bindable protected Form form = new Form();
-    @Bindable protected Form optionsForm = new Form();
+    private Form form = new Form("form");
+    private Form optionsForm = new Form("optionsForm");
 
     private Select select = new Select("select");
     private Checkbox allFieldsRequired = new Checkbox("allFieldsRequired");
@@ -79,6 +78,9 @@ public class StandardControlsForm extend
     // Constructor ------------------------------------------------------------
 
     public StandardControlsForm() {
+        addControl(form);
+        addControl(optionsForm);
+
         form.setErrorsPosition(Form.POSITION_TOP);
 
         // Controls FieldSet

Modified: click/trunk/click/examples/src/org/apache/click/examples/page/form/dynamic/PopulateOnSelect.java
URL: http://svn.apache.org/viewvc/click/trunk/click/examples/src/org/apache/click/examples/page/form/dynamic/PopulateOnSelect.java?rev=1052766&r1=1052765&r2=1052766&view=diff
==============================================================================
--- click/trunk/click/examples/src/org/apache/click/examples/page/form/dynamic/PopulateOnSelect.java
(original)
+++ click/trunk/click/examples/src/org/apache/click/examples/page/form/dynamic/PopulateOnSelect.java
Sat Dec 25 10:48:23 2010
@@ -32,7 +32,6 @@ import org.apache.click.element.Element;
 import org.apache.click.element.JsScript;
 import org.apache.click.examples.page.BorderPage;
 import org.apache.click.extras.control.TabbedForm;
-import org.apache.click.util.Bindable;
 import org.apache.click.util.ClickUtils;
 import org.apache.commons.lang.StringUtils;
 
@@ -48,7 +47,7 @@ public class PopulateOnSelect extends Bo
     private static final String GAUTENG_PROVINCE = "GP";
     private static final String WESTERN_CAPE = "WC";
 
-    @Bindable protected TabbedForm form = new TabbedForm("form");
+    private TabbedForm form = new TabbedForm("form");
 
     private Select state = new Select("state", true);
     private Select city = new Select("city", true);
@@ -61,6 +60,8 @@ public class PopulateOnSelect extends Bo
     public void onInit() {
         super.onInit();
 
+        addControl(form);
+
         FieldSet fieldSet = new FieldSet("select");
         form.addTabSheet(fieldSet);
 



Mime
View raw message