-
Bug
-
Resolution: Unresolved
-
Normal
-
None
-
8.6.0.1
-
None
zul.wgt.Toolbar.removeChild(child) throws exception once customer client code applies insertBefore(child, sibling) on Toolbar!
Reason is, that Toolbar.removeChild(child) expects non-empty node for child:
{{ removeChild: function (child)
,}}
As removeChild(child) is used inside insertBefore(child, sibling), which conditionally applies appendChild(child) before, child.node can be NULL, which is not checked by Toolbar.removeChild(child)!
Some background: Because Toolbar was missing "overflow" feature before 8.6, we developed same functionality some time ago. We considered to use native "overflow" feature from 8.6, but its not flexible enough so far (e.g. fix markup of overflow button).
As workaround, we temporarily replaced Toolbar.removeChild(child):
{{zk.afterLoad('zul.wgt', function () {
new zul.wgt.Toolbar(); // force init
zul.wgt.Toolbar.prototype.removeChild = function()
});}}
- relates to
-
ZK-4226 Toolbar: overflowPopup="true" and align="end" have conflict
- Open