-
FEATURED COMPONENTS
First time here? Check out the FAQ!
1 | initial version | |
To make a long story short, I created an demo on zkfiddle (link below) http://zkfiddle.org/sample/2lmagsn/5-Mutli-Select-Listbox
It's a multi select listbox with two data models. The show button will show you how many items that are selected. By checking or unchecking the checkbox , the listbox will switch between two different data models.
instructions 1. run the sample 2. select item4 3. click show , see 1 item are selected. 4. check the checkbox, it will switch to another model. 5. select any item you want 6. clcik show, see how many items are selected.
My question is how i can clear all the itmes in the selectedItems set when the data model is changed. The items in two data models are just mixed into one selectedItems set.
Thank you.