PDA

View Full Version : [FIXED] [1.2.3] AbstractStoreSelectionModel calls onSelectChange() too early



Adam Ward
10 Mar 2009, 10:45 AM
The AbstractStoreSelectionModel calls the onSelectChange(M model, boolean select) before the classes internal variable selected is updated. The following lines in AbstractStoreSelectionModel.java (lines 309-311):


onSelectChange(model, true);
selected.add(model);
lastSelected = model;


should be changed to:



selected.add(model);
lastSelected = model;
onSelectChange(model, true);


With the fix, we can now trust the selected member variable in the concrete implementation of onSelectChange(M, boolean).

sven
10 Mar 2009, 10:53 AM
Yes, i already changed this :) Will be part of the next release

sven
1 Apr 2009, 4:33 AM
Fixed in SVN.