Understanding JComboBoxModel

69 Views Asked by At

I am getting what, to me, seems like odd behavior. I've created createComboBoxModel. I then create 2 new JComboBoxes and add the model to each as ComboBoxDefaultModel. Although the combo boxes are different instances, using the model seems to somehow tie the 2 together. When I make a selection in one combobox it forces the same selection in the other combobox as well. Is this the way it is supposed to behave and if so why? If not then do I have some kind of coding error that causes this behavior? TIA.

0

There are 0 best solutions below