You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Plugins slick.cellselectionmodel and slick.rowselectionmodel have function setSelectedRanges which sets selected range and fires onSelectedRangesChanged event.
Unfortunately the event is fired in any case even if range didn't change. As consequence grid fires onSelectedRowsChanged event.
That can (and does) have some useless processing.
For example slick.checkboxselectcolumn plugin in its handleSelectedRowsChanged updates column header.
function setSelectedRanges(ranges) {
_ranges = ranges;
_self.onSelectedRangesChanged.notify(_ranges);
}
The text was updated successfully, but these errors were encountered:
evil-shrike
changed the title
Prevent excessive onSelectedRangesChanged events on
Prevent useless onSelectedRangesChanged events in selectionmodels' setSelectedRanges
May 29, 2015
Plugins slick.cellselectionmodel and slick.rowselectionmodel have function
setSelectedRanges
which sets selected range and firesonSelectedRangesChanged
event.Unfortunately the event is fired in any case even if range didn't change. As consequence grid fires
onSelectedRowsChanged
event.That can (and does) have some useless processing.
For example slick.checkboxselectcolumn plugin in its
handleSelectedRowsChanged
updates column header.I suggest to put a simple check for empty range:
The text was updated successfully, but these errors were encountered: