Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-1070

onSelect is not fired in listbox mold select

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: 6.0.0
    • Fix Version/s: 6.0.1
    • Component/s: Components
    • Labels:
      None

      Description

      <zk>
      <div>
      <zscript>
      org.zkoss.zul.ListModelList list = new org.zkoss.zul.ListModelList();
      list.add("A");
      list.add("B");
      list.add("C");
      </zscript>
      		<label multiline="true">
      		[onSelect not fired if there is a listheader]
      		1.Both listbox should select to B.
      		2.select C on listbox 1, it should pop up a message 'onSelect .....' (will not if bug is not fixed)
      		3.select C on listbox 2,  it should pop up a message 'onSelect .....'
      		</label>
      	<window apply="org.zkoss.bind.BindComposer"
      		title="a title" width="400px">
      
      		<listbox mold="select"  width="100%" model="${list}"
      			onSelect='alert("onSelect "+self.getSelectedItem())' onCreate='list.addToSelection("B")'>
      			<listhead>
      				<listheader></listheader>
      			</listhead>
      			<template name="model">
      				<listitem>
      					<listcell label="${each}"></listcell>
      				</listitem>
      			</template>
      		</listbox>
      		<listbox mold="select"  width="100%" model="${list}"
      			onSelect='alert("onSelect "+self.getSelectedItem())' onCreate='list.addToSelection("B")'>
      			<template name="model">
      				<listitem>
      					<listcell label="${each}"></listcell>
      				</listitem>
      			</template>
      		</listbox>
      	</window>
      	</div>
      </zk>
      
      

        Attachments

          Activity

            People

            • Assignee:
              TonyQ TonyQ
              Reporter:
              dennis dennis
            • Votes:
              1 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: