-
Bug
-
Resolution: Fixed
-
Normal
-
6.5.3
-
Security Level: Jimmy
-
None
the issue occurs only when you use the cross x button to remove all selected items from Chosenbox and then click outside of Chosenbox (if you tab out using keyboard the emtyMessage reappears).
Test case
<zk> <window id="win" apply="org.zkoss.support.WindowComposer"> <chosenbox id="cbox" width="500px" emptyMessage="choose a person"></chosenbox> </window> </zk> {code:title=WindowComposer.java|borderStyle=solid} public class WindowComposer extends SelectorComposer<Window> { @Wire Chosenbox cbox; public void doAfterCompose(Window win) throws Exception { super.doAfterCompose(win); ArrayList<String> alist = new ArrayList<String>(); alist.add("Tony"); alist.add("Thor"); alist.add("Peter"); cbox.setModel(new ListModelList<String>(alist)); }
Steps to reproduce
1. Select some items
2. Remove items by clicking the x button on selected item lables
3. after the selection is empty click outside of chosenbox
Expected Result:
Chosenbox shows the emptyMessage
Actual Result:
Chosenbox doesn't show emptyMessage (it can show if you tab out after selection is empty)