Commit f6c7f64a authored by konovalovsergey's avatar konovalovsergey

comment delete table column; remove console.log

parent f416b6ad
...@@ -4604,13 +4604,14 @@ parserFormula.prototype.parse = function(local, digitDelim) { ...@@ -4604,13 +4604,14 @@ parserFormula.prototype.parse = function(local, digitDelim) {
else if (_tableTMP = parserHelp.isTable.call(this, this.Formula, this.pCurrPos, local)) { else if (_tableTMP = parserHelp.isTable.call(this, this.Formula, this.pCurrPos, local)) {
found_operand = new cStrucTable(_tableTMP, this.wb, this.ws); found_operand = new cStrucTable(_tableTMP, this.wb, this.ws);
if (found_operand.type == cElementType.error) { //todo undo delete column
/*используется неверный именованный диапазон или таблица*/ // if (found_operand.type == cElementType.error) {
this.error.push(c_oAscError.ID.FrmlAnotherParsingError); // /*используется неверный именованный диапазон или таблица*/
this.outStack = []; // this.error.push(c_oAscError.ID.FrmlAnotherParsingError);
this.elemArr = []; // this.outStack = [];
return false; // this.elemArr = [];
} // return false;
// }
if (found_operand.type != cElementType.error) { if (found_operand.type != cElementType.error) {
this.RefPos.push({ this.RefPos.push({
......
...@@ -869,14 +869,8 @@ ...@@ -869,14 +869,8 @@
return; return;
} }
var notifyData = {type: AscCommon.c_oNotifyType.Dirty}; var notifyData = {type: AscCommon.c_oNotifyType.Dirty};
console.time('all');
console.time('_buildDependency');
this.buildDependency(); this.buildDependency();
console.time('_buildDependency');
console.time('broadscastVolatile');
this._broadscastVolatile(notifyData); this._broadscastVolatile(notifyData);
console.timeEnd('broadscastVolatile');
console.time('broadcastCells');
var calcTrack = []; var calcTrack = [];
var noCalcTrack = []; var noCalcTrack = [];
while (this.changedCell || this.changedDefName) { while (this.changedCell || this.changedDefName) {
...@@ -884,8 +878,6 @@ ...@@ -884,8 +878,6 @@
this._broadcastCells(notifyData, calcTrack); this._broadcastCells(notifyData, calcTrack);
} }
this._broadcastCellsEnd(); this._broadcastCellsEnd();
console.timeEnd('broadcastCells');
console.time('calculate');
for (var i = 0; i < noCalcTrack.length; ++i) { for (var i = 0; i < noCalcTrack.length; ++i) {
var formula = noCalcTrack[i]; var formula = noCalcTrack[i];
//defName recalc when calc formula containing it. no need calc it //defName recalc when calc formula containing it. no need calc it
...@@ -897,8 +889,6 @@ ...@@ -897,8 +889,6 @@
formula.calculate(); formula.calculate();
} }
} }
console.timeEnd('calculate');
console.time('cleanCellCache');
for (var i in this.cleanCellCache) { for (var i in this.cleanCellCache) {
this.wb.handlers.trigger("cleanCellCache", i, {0: this.cleanCellCache[i]}, this.wb.handlers.trigger("cleanCellCache", i, {0: this.cleanCellCache[i]},
AscCommonExcel.c_oAscCanChangeColWidth.none); AscCommonExcel.c_oAscCanChangeColWidth.none);
...@@ -906,8 +896,6 @@ ...@@ -906,8 +896,6 @@
this.cleanCellCache = {}; this.cleanCellCache = {};
AscCommonExcel.g_oVLOOKUPCache.clean(); AscCommonExcel.g_oVLOOKUPCache.clean();
AscCommonExcel.g_oHLOOKUPCache.clean(); AscCommonExcel.g_oHLOOKUPCache.clean();
console.timeEnd('cleanCellCache');
console.timeEnd('all');
}, },
calcAll: function(sheetId){ calcAll: function(sheetId){
var worksheets = []; var worksheets = [];
...@@ -1218,23 +1206,15 @@ ...@@ -1218,23 +1206,15 @@
}, },
getByCells: function(cells) { getByCells: function(cells) {
var res = []; var res = [];
console.time('getByCells');
console.time('getNodeAll');
var nodes = this.yTree.getNodeAll(); var nodes = this.yTree.getNodeAll();
console.timeEnd('getNodeAll');
console.time('forin');
var cellArr = []; var cellArr = [];
for (var cellIndex in cells) { for (var cellIndex in cells) {
cellArr.push(cellIndex - 0); cellArr.push(cellIndex - 0);
} }
console.timeEnd('forin');
console.time('sort');
//sort завязана на реализацию getCellIndex //sort завязана на реализацию getCellIndex
cellArr.sort(function(a, b) { cellArr.sort(function(a, b) {
return a - b; return a - b;
}); });
console.timeEnd('sort');
console.time('other');
if (cellArr.length > 0 && nodes.length > 0) { if (cellArr.length > 0 && nodes.length > 0) {
var curNodes = {}; var curNodes = {};
var curY = null; var curY = null;
...@@ -1284,8 +1264,6 @@ ...@@ -1284,8 +1264,6 @@
} }
} }
} }
console.timeEnd('other');
console.timeEnd('getByCells');
//for(var i = 0 ; i < res.length; ++i){ //for(var i = 0 ; i < res.length; ++i){
// res[i].isOutput = false; // res[i].isOutput = false;
//} //}
......
...@@ -5857,11 +5857,12 @@ TablePart.prototype.deleteTableColumns = function(activeRange) ...@@ -5857,11 +5857,12 @@ TablePart.prototype.deleteTableColumns = function(activeRange)
var deleted = this.TableColumns.splice(startCol, diff); var deleted = this.TableColumns.splice(startCol, diff);
this.removeDependencies(deleted); this.removeDependencies(deleted);
var deletedMap = {}; //todo undo
for (var i = 0; i < deleted.length; ++i) { // var deletedMap = {};
deletedMap[deleted[i].Name] = 1; // for (var i = 0; i < deleted.length; ++i) {
} // deletedMap[deleted[i].Name] = 1;
this.handlers.trigger("deleteColumnTablePart", this.DisplayName, deletedMap); // }
// this.handlers.trigger("deleteColumnTablePart", this.DisplayName, deletedMap);
} }
}; };
......
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