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

waitSave перенес в проверку до сохранения документа

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@60270 954022d7-b5bf-4e40-9824-e11837661b57
parent 3ec8e6b6
...@@ -1430,7 +1430,7 @@ asc_docs_api.prototype.Share = function(){ ...@@ -1430,7 +1430,7 @@ asc_docs_api.prototype.Share = function(){
function OnSave_Callback(e) { function OnSave_Callback(e) {
if (false == e["saveLock"] && false === editor.waitSave) { if (false == e["saveLock"]) {
editor.sync_StartAction(c_oAscAsyncActionType.Information, c_oAscAsyncAction.Save); editor.sync_StartAction(c_oAscAsyncActionType.Information, c_oAscAsyncAction.Save);
if (c_oAscCollaborativeMarksShowType.LastChanges === editor.CollaborativeMarksShowType) if (c_oAscCollaborativeMarksShowType.LastChanges === editor.CollaborativeMarksShowType)
...@@ -1467,7 +1467,8 @@ function OnSave_Callback(e) { ...@@ -1467,7 +1467,8 @@ function OnSave_Callback(e) {
} }
asc_docs_api.prototype.asc_Save = function () { asc_docs_api.prototype.asc_Save = function () {
if (true === this.canSave) // waitSave - означает, что сейчас происходит вставка данных и сохранять до окончания нельзя
if (false === this.waitSave && true === this.canSave)
{ {
this.canSave = false; this.canSave = false;
this.CoAuthoringApi.askSaveChanges(OnSave_Callback); this.CoAuthoringApi.askSaveChanges(OnSave_Callback);
......
...@@ -2779,7 +2779,7 @@ asc_docs_api.prototype.Share = function(){ ...@@ -2779,7 +2779,7 @@ asc_docs_api.prototype.Share = function(){
} }
function OnSave_Callback(e) { function OnSave_Callback(e) {
if (false == e["saveLock"] && false === editor.waitSave) { if (false == e["saveLock"]) {
editor.sync_StartAction(c_oAscAsyncActionType.Information, c_oAscAsyncAction.Save); editor.sync_StartAction(c_oAscAsyncActionType.Information, c_oAscAsyncAction.Save);
if (c_oAscCollaborativeMarksShowType.LastChanges === editor.CollaborativeMarksShowType) if (c_oAscCollaborativeMarksShowType.LastChanges === editor.CollaborativeMarksShowType)
...@@ -2817,7 +2817,8 @@ function OnSave_Callback(e) { ...@@ -2817,7 +2817,8 @@ function OnSave_Callback(e) {
asc_docs_api.prototype.asc_Save = function () asc_docs_api.prototype.asc_Save = function ()
{ {
if (true === this.canSave) // waitSave - означает, что сейчас происходит вставка данных и сохранять до окончания нельзя
if (false === this.waitSave && true === this.canSave)
{ {
this.canSave = false; this.canSave = false;
this.CoAuthoringApi.askSaveChanges(OnSave_Callback); this.CoAuthoringApi.askSaveChanges(OnSave_Callback);
......
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