Commit cf062104 authored by Alexander.Trofimov's avatar Alexander.Trofimov

move call Continue_FastCollaborativeEditing to autoSave function

parent b0fbd020
......@@ -2854,8 +2854,6 @@ function CEditorPage(api)
_c.m_nCurrentTimeClearCache = 0;
_c.m_oDrawingDocument.CheckFontCache();
}
this.m_oLogicDocument.Continue_FastCollaborativeEditing();
};
this.OnScroll = function()
{
......
......@@ -1907,24 +1907,28 @@ background-repeat: no-repeat;\
this.asc_Save(true);
this.lastSaveTime = _curTime;
} else {
var _bIsWaitScheme = false;
if (this.WordControl.m_oDrawingDocument &&
!this.WordControl.m_oDrawingDocument.TransitionSlide.IsPlaying() && History.Points &&
History.Index >= 0 && History.Index < History.Points.length) {
if ((_curTime - History.Points[History.Index].Time) < this.intervalWaitAutoSave) {
_bIsWaitScheme = true;
if (AscCommon.CollaborativeEditing.Is_Fast() && !AscCommon.CollaborativeEditing.Is_SingleUser()) {
this.WordControl.m_oLogicDocument.Continue_FastCollaborativeEditing();
} else {
var _bIsWaitScheme = false;
if (this.WordControl.m_oDrawingDocument &&
!this.WordControl.m_oDrawingDocument.TransitionSlide.IsPlaying() && History.Points &&
History.Index >= 0 && History.Index < History.Points.length) {
if ((_curTime - History.Points[History.Index].Time) < this.intervalWaitAutoSave) {
_bIsWaitScheme = true;
}
}
}
if (!_bIsWaitScheme) {
var _interval = (AscCommon.CollaborativeEditing.m_nUseType <= 0) ? this.autoSaveGapSlow :
this.autoSaveGapFast;
if (!_bIsWaitScheme) {
var _interval = (AscCommon.CollaborativeEditing.m_nUseType <= 0) ? this.autoSaveGapSlow :
this.autoSaveGapFast;
if ((_curTime - this.lastSaveTime) > _interval) {
if (History.Have_Changes(true) == true) {
this.asc_Save(true);
if ((_curTime - this.lastSaveTime) > _interval) {
if (History.Have_Changes(true) == true) {
this.asc_Save(true);
}
this.lastSaveTime = _curTime;
}
this.lastSaveTime = _curTime;
}
}
}
......
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