Commit 7e7abffc authored by Alexander.Trofimov's avatar Alexander.Trofimov Committed by Alexander.Trofimov

fix bug #27392

Добавил проверки на ограничение строк/столбцов (однако в модели стоит обработать такую ситуацию)

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@59484 954022d7-b5bf-4e40-9824-e11837661b57
parent a831b600
......@@ -1298,7 +1298,7 @@
}
if (1 === fullRecalc)
this.nColsCount = Math.max(this.nColsCount, i);
this.nColsCount = Math.min(Math.max(this.nColsCount, i), gc_nMaxCol);
};
/**
......@@ -1350,7 +1350,7 @@
}
if (1 === fullRecalc)
this.nRowsCount = Math.max(this.nRowsCount, i);
this.nRowsCount = Math.min(Math.max(this.nRowsCount, i), gc_nMaxRow);
};
/** Вычисляет диапазон индексов видимых колонок */
......@@ -4569,8 +4569,8 @@
* @return {Range}
*/
WorksheetView.prototype._getCell = function (col, row) {
this.nRowsCount = Math.max(this.model.getRowsCount() + 1, this.rows.length);
this.nColsCount = Math.max(this.model.getColsCount() + 1, this.cols.length);
this.nRowsCount = Math.min(Math.max(this.model.getRowsCount() + 1, this.rows.length), gc_nMaxRow);
this.nColsCount = Math.min(Math.max(this.model.getColsCount() + 1, this.cols.length), gc_nMaxCol);
if (col < 0 || col >= this.nColsCount || row < 0 || row >= this.nRowsCount)
return null;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment