Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'master' of github.com:zkoss/zk

  • Loading branch information...
commit a06b28277b87adf3dba77705ebd897658b249192 2 parents 74a15a7 + 8173180
@jumperchen jumperchen authored
View
7 zk/src/org/zkoss/zk/ui/impl/UiEngineImpl.java
@@ -1465,6 +1465,13 @@ void visualizeErrors(Execution exec, UiVisualizer uv, List<Throwable> errs) {
return; //done
} catch (Throwable ex) {
log.realCause("Unable to generate custom error page, "+location, ex);
+ } finally {
+ // Bug ZK-1144 in JBoss
+ exec.removeAttribute("javax.servlet.error.message");
+ exec.removeAttribute("javax.servlet.error.exception");
+ exec.removeAttribute("javax.servlet.error.exception_type");
+ exec.removeAttribute("javax.servlet.error.status_code");
+ exec.removeAttribute("javax.servlet.error.error_page");
}
}
View
14 zkbind/src/org/zkoss/bind/impl/BinderImpl.java
@@ -1856,20 +1856,26 @@ private void loadComponentProperties(Component comp,boolean loadinit) {
if (compBindings != null) {
for(String key : compBindings.keySet()) {
final BindingKey bkey = getBindingKey(comp, key);
- _formBindingHandler.doInit(comp,bkey);
+ if(loadinit){
+ _formBindingHandler.doInit(comp,bkey);
+ }
_formBindingHandler.doLoad(comp,bkey);
}
for(String key : compBindings.keySet()) {
final BindingKey bkey = getBindingKey(comp, key);
- _propertyBindingHandler.doInit(comp,bkey);
+ if(loadinit){
+ _propertyBindingHandler.doInit(comp,bkey);
+ }
_propertyBindingHandler.doLoad(comp,bkey);
}
for(String key : compBindings.keySet()) {
final BindingKey bkey = getBindingKey(comp, key);
- _childrenBindingHandler.doInit(comp,bkey);
+ if(loadinit){
+ _childrenBindingHandler.doInit(comp,bkey);
+ }
+
_childrenBindingHandler.doLoad(comp,bkey);
}
-
}
}
View
2  zkdoc/release-note
@@ -8,6 +8,7 @@ ZK 6.0.2
ZK-1118: Vertical scrollbar appears when listbox with fixed rows and sizedByContent is true exceeds browser width
ZK-1136: Clients.showNotification(String) throws JS error when used with Include in defer mode
ZK-1135: Notification is not correctly displayed on IE8 (compatibility view turned OFF)
+ ZK-1144: error-page in JBoss causes IllegalStateException
* Upgrade Notes
@@ -104,6 +105,7 @@ May 2, 2012
ZK-1096: Listbox multiselect bug with draggable on
ZK-1101: Portallayout.setPanel() doesn't behave as expected
ZK-1100: Menuitem.setImage() doesn't work in menubar
+ ZK-1139: ZK Bind loads "init" annotations no matter if "loadinit" parameter TRUE or FALSE
* Upgrade Notes
+ Component.queryAll() returns Iterable<Component> instead of List<Component>
View
50 zktest/src/archive/bind/issue/B01139LoadInit.zul
@@ -0,0 +1,50 @@
+<!--
+B01139LoadInit.zul
+
+ Purpose:
+
+ Description:
+
+ History:
+ Mon, May 21, 2012 12:00:17 AM, Created by Iantsai
+
+Copyright (C) 2012 Potix Corporation. All Rights Reserved.
+-->
+
+<zk xmlns:n="native">
+<n:h5>Testing step:</n:h5>
+ <n:ol>
+ <n:li> make the checkbox in caption become unchecked </n:li>
+ <n:li> change the value of "name" textbox</n:li>
+ <n:li> click "change name" button</n:li>
+ <n:li> the value of name should not changed</n:li>
+ </n:ol>
+
+<window id="myWin" title="binder loadComponent loadinit false" border="normal"
+ apply="org.zkoss.bind.BindComposer"
+ viewModel="@id('vm') @init('org.zkoss.zktest.bind.basic.CompositeVM')">
+ <caption>
+ <checkbox id="liChk" label="load Init" checked="true" />
+
+ </caption>
+
+
+ <grid>
+ <rows>
+ <row>
+ <textbox id="nameTexb" value="@load(vm.name)"></textbox>
+ <button id="changeNameBtn" label="change name">
+ <attribute name="onClick"><![CDATA[
+ myWin$composer.getViewModel().setName(nameTexb.getValue());
+ myWin$composer.getBinder().loadComponent(myWin, liChk.isChecked());
+ ]]></attribute>
+ </button>
+ </row>
+ <row>name (init binding): <label id="nameLbl" value="@init(vm.name)"/></row>
+ <row>title: <label value="@bind(vm.title)"/> </row>
+ <row>value: <label value="@bind(vm.value)"/> </row>
+ </rows>
+ </grid>
+
+</window>
+</zk>
View
50 zktest/src/archive/test2/B60-ZK-1139.zul
@@ -0,0 +1,50 @@
+<!--
+B60-ZK-1139.zul
+
+ Purpose:
+
+ Description:
+
+ History:
+ Mon, May 21, 2012 12:00:17 AM, Created by Iantsai
+
+Copyright (C) 2012 Potix Corporation. All Rights Reserved.
+-->
+
+<zk xmlns:n="native">
+<n:h5>Testing step:</n:h5>
+ <n:ol>
+ <n:li> make the checkbox in caption become unchecked </n:li>
+ <n:li> change the value of "name" textbox</n:li>
+ <n:li> click "change name" button</n:li>
+ <n:li> the value of name should not changed</n:li>
+ </n:ol>
+
+<window id="myWin" title="binder loadComponent loadinit false" border="normal"
+ apply="org.zkoss.bind.BindComposer"
+ viewModel="@id('vm') @init('org.zkoss.zktest.bind.basic.CompositeVM')">
+ <caption>
+ <checkbox id="liChk" label="load Init" checked="true" />
+
+ </caption>
+
+
+ <grid>
+ <rows>
+ <row>
+ <textbox id="nameTexb" value="@load(vm.name)"></textbox>
+ <button id="changeNameBtn" label="change name">
+ <attribute name="onClick"><![CDATA[
+ myWin$composer.getViewModel().setName(nameTexb.getValue());
+ myWin$composer.getBinder().loadComponent(myWin, liChk.isChecked());
+ ]]></attribute>
+ </button>
+ </row>
+ <row>name (init binding): <label id="nameLbl" value="@init(vm.name)"/></row>
+ <row>title: <label value="@bind(vm.title)"/> </row>
+ <row>value: <label value="@bind(vm.value)"/> </row>
+ </rows>
+ </grid>
+
+</window>
+</zk>
Please sign in to comment.
Something went wrong with that request. Please try again.