code: function recalculateRowHeights(tableGrid, heights) {
          var allRows = tableGrid.getAllRows();
          return Tools.map(allRows, function (row, i) {
            return {
              element: row.element,
              height: heights[i]
            };
          });
        }
docs: Calculate row heights.