- 
    Type:Bug 
- 
    Resolution: Fixed
- 
    Priority:Major 
- 
    Affects Version/s: 8.5.2, 8.5.2.1
- 
    Component/s: Components
- 
    Security Level: Jimmy
- 
        ZK 8.6.1 S1
- 
        None
Steps to Reproduce
    <library-property>
        <name>org.zkoss.zul.nativebar</name>
        <value>false</value>
    </library-property>
Cannot use anymore neither sizedByContent="true" in Listbox/Grid nor hflex="min" in listheader.
Please check this simple zul.
<window title="Listbox"> <listbox checkmark="false" multiple="false" style="border:none" sizedByContent="true"> <listhead> <listheader label="Client" /> <listheader label="Description" /> </listhead> <listitem style="white-space: nowrap"> <listcell label="XXX" hflex="min" /> <listcell label="XXX description" /> </listitem> </listbox> </window>
simplified:
    <listbox>
        <listhead>
            <listheader label="Client" hflex="min"/>
        </listhead>
        <listitem>
            <listcell label="aaa" hflex="min"/>
        </listitem>
    </listbox>
Current Result
Data are either not displayed properly or even crash with:
Uncaught TypeError: Cannot read property 'firstChild' of null
    at _calcMinWd (zul.mesh.wpd:62)
    at init._calcMinWds (zul.mesh.wpd:1430)
    at init.beforeMinFlex_ (zul.mesh.wpd:2917)
    at Object.fixMinFlex (zk.wpd:27788)
    at Object.fixFlex (zk.wpd:27678)
    at init.onSize (zk.wpd:27583)
    at _invoke (zk.wpd:15028)
    at init.fire (zk.wpd:15011)
    at _fire (zk.wpd:15154)
    at Object.fireDown (zk.wpd:15371)
"Error code 3: ZK error, after mounting. 
Something went wrong while loading the page."
Expected Result
- no error.
- show a non-native scrollbar
debug info
- since 8.5.2, there is no .z-listheader-bar rendered when navtivebar=false
Workaround
see attached zk-4071.js
- is duplicated by
- 
                    ZK-4097 nativebar=false causes "after mounting error" -         
- Closed
 
-