-
Bug
-
Resolution: Fixed
-
Major
-
8.0.3, 8.0.4.2
-
None
-
Security Level: Jean
-
None
Simplified case
Steps to Reproduce
- load the attached zul
- enter "ab" in the textbox
- label shows "ab"
- then enter "i" to invalidate, the label shows "abi"
- then enter "cd"
Current Result
the label still shows "abi" and no onChange event is fired
Expected Result
the label shows as the textbox's value and an onChange event is fired after redrawing
Debug Info
- it doesn't happen before 8.0.2 (included)
- the original use case is: a textbox in inside a Listheader, and Listbox redraws itself causes no onChange event fired.
Root cause
- fix for
ZK-3326
Workaround
<script><![CDATA[ /* */ zk.afterLoad('zul.inp', function() { var xInputWidget = {}; zul.inp.InputWidget._onChanging = function (timeout) { if (this.desktop) { var inp = this.getInputNode(), val = this.valueEnter_ || inp.value; if (this._lastChg != val) { this._lastChg = val; var valsel = this.valueSel_; this.valueSel_ = null; if (this.isListen('onChanging')) this.fire('onChanging', zul.inp.InputWidget._onChangeData(this, {value: val}, valsel == val), {ignorable: 1, rtags: {onChanging: 1}}, timeout || 5); if (this._instant) this.updateChange_(); } } } });//zk.afterLoad ]]></script>
- avoid triggering invalidate()
- relates to
-
ZK-3326 Bandbox unexpected onChanging event
- Closed