Commit cb6ccd4f authored by Alexander.Trofimov's avatar Alexander.Trofimov Committed by Alexander.Trofimov

Теперь на _calcCellsTextMetrics мы получаем только не пустые ячейки для строки...

Теперь на _calcCellsTextMetrics мы получаем только не пустые ячейки для строки (ускорил открытие файлов с большим числом пустых колонок)
Баг http://bugzserver/show_bug.cgi?id=17545

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@50575 954022d7-b5bf-4e40-9824-e11837661b57
parent b03f9a49
...@@ -2204,6 +2204,9 @@ function Row(worksheet) ...@@ -2204,6 +2204,9 @@ function Row(worksheet)
}; };
Row.prototype = Row.prototype =
{ {
getCells : function () {
return this.c;
},
getId : function() getId : function()
{ {
return this.id; return this.id;
......
...@@ -3488,11 +3488,21 @@ ...@@ -3488,11 +3488,21 @@
if (range === undefined) { if (range === undefined) {
range = asc_Range(0, 0, this.cols.length - 1, this.rows.length - 1); range = asc_Range(0, 0, this.cols.length - 1, this.rows.length - 1);
} }
var rowModel, rowCells, cellColl;
for (var row = range.r1; row <= range.r2; ++row) { for (var row = range.r1; row <= range.r2; ++row) {
if (this.height_1px > this.rows[row].height) {continue;} if (this.height_1px > this.rows[row].height) {continue;}
for (var col = range.c1; col <= range.c2; ++col) { // Теперь получаем только не пустые ячейки для строки
if (this.width_1px > this.cols[col].width) {continue;} rowModel = this.model._getRowNoEmpty(row);
col = this._addCellTextToCache(col, row); if (null === rowModel)
continue;
rowCells = rowModel.getCells();
for (cellColl in rowCells) {
if (!rowCells.hasOwnProperty(cellColl))
continue;
cellColl = cellColl - 0;
if (this.width_1px > this.cols[cellColl].width) {continue;}
this._addCellTextToCache(cellColl, row);
} }
} }
this.isChanged = false; this.isChanged = false;
......
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