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

OpenWarning - для предупреждения по открытию

bug #25857

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@68224 954022d7-b5bf-4e40-9824-e11837661b57
parent 6fdb9e00
...@@ -1466,6 +1466,11 @@ var editor; ...@@ -1466,6 +1466,11 @@ var editor;
// Меняем тип состояния (на никакое) // Меняем тип состояния (на никакое)
this.advancedOptionsAction = c_oAscAdvancedOptionsAction.None; this.advancedOptionsAction = c_oAscAdvancedOptionsAction.None;
// Были ошибки при открытии, посылаем предупреждение
if (0 < this.wbModel.openErrors.length) {
this.sendEvent('asc_onError', c_oAscError.ID.OpenWarning, c_oAscError.Level.NoCritical);
}
//this.asc_Resize(); // Убрал, т.к. сверху приходит resize (http://bugzserver/show_bug.cgi?id=14680) //this.asc_Resize(); // Убрал, т.к. сверху приходит resize (http://bugzserver/show_bug.cgi?id=14680)
}; };
......
...@@ -64,7 +64,9 @@ var c_oAscError = { ...@@ -64,7 +64,9 @@ var c_oAscError = {
CannotFillRange: -81, CannotFillRange: -81,
UserDrop: -100, UserDrop: -100,
Warning: -101 Warning: -101,
OpenWarning: 500
} }
}; };
var c_oAscConfirm = { var c_oAscConfirm = {
......
...@@ -1931,6 +1931,8 @@ function Workbook(eventsHandlers, oApi){ ...@@ -1931,6 +1931,8 @@ function Workbook(eventsHandlers, oApi){
this.aCollaborativeChangeElements = []; this.aCollaborativeChangeElements = [];
this.wsHandlers = null; this.wsHandlers = null;
this.openErrors = [];
} }
Workbook.prototype.init=function(bNoBuildDep){ Workbook.prototype.init=function(bNoBuildDep){
if(this.nActive < 0) if(this.nActive < 0)
...@@ -3226,11 +3228,15 @@ Woorksheet.prototype.initPostOpen = function(handlers){ ...@@ -3226,11 +3228,15 @@ Woorksheet.prototype.initPostOpen = function(handlers){
} }
} }
} }
if(oFormulaExt.v && oFormulaExt.v.length <= c_oAscMaxFormulaLength) { if(oFormulaExt.v) {
if (oFormulaExt.v.length <= c_oAscMaxFormulaLength) {
oCell.setFormula(oFormulaExt.v); oCell.setFormula(oFormulaExt.v);
if(oFormulaExt.ca) { if(oFormulaExt.ca) {
oCell.sFormulaCA = true; oCell.sFormulaCA = true;
} }
} else {
this.workbook.openErrors.push(oCell.getName());
}
} }
/* /*
......
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