Fixed checkbox in column header doesn't work when using Grouping

When we use Grouping, checkbox in column header won't work correctly because it compares the total number of rendered rows to selected rows which never include group header rows.