We are using the myGrid.addSelectionChangedHandler() to dynamically enable or disable some other components on the page, depending on certain attributes in the selected records of the grid. The problem is when users hit the select all checkbox, this fires the addSelectionChangedHandler for every record, and it is slowing down the grid quite a lot.
Is there a smarter way of handling the select all checkbox? I have thought of using the addHeaderClick event to listen for the checkbox click, but it seems like a hack, and would still require selecting all the records and causing the addSelectionChangedHandler to fire anyway. What I am looking for is some sort of addSelectAllChangedHandler() that wouldn't fire for every record but just fires once.
Is there a smarter way of handling the select all checkbox? I have thought of using the addHeaderClick event to listen for the checkbox click, but it seems like a hack, and would still require selecting all the records and causing the addSelectionChangedHandler to fire anyway. What I am looking for is some sort of addSelectAllChangedHandler() that wouldn't fire for every record but just fires once.
Comment