mirror of
https://github.com/cryptpad/cryptpad.git
synced 2026-09-14 11:05:41 +05:00
Merge remote-tracking branch 'origin/5.3-rc' into 5.3-rc
This commit is contained in:
commit
1fc889f1c5
@ -1970,7 +1970,7 @@ CWordCollaborativeEditing.prototype.Release_Locks=function(){var UnlockCount=thi
|
||||
AscCommonWord.CDocument)editor.sync_UnLockDocumentProps();else if(this.m_aNeedUnlock[Index]instanceof AscCommon.CComment)editor.sync_UnLockComment(this.m_aNeedUnlock[Index].Get_Id());else if(this.m_aNeedUnlock[Index]instanceof AscCommonWord.CGraphicObjects)editor.sync_UnLockDocumentSchema();else if(this.m_aNeedUnlock[Index]instanceof AscCommon.CCore)editor.sendEvent("asc_onLockCore",false)}else if(AscCommon.locktype_Other3===CurLockType)this.m_aNeedUnlock[Index].Lock.Set_Type(AscCommon.locktype_Other,
|
||||
false)}};
|
||||
CWordCollaborativeEditing.prototype.OnEnd_Load_Objects=function(){AscCommon.CollaborativeEditing.Set_GlobalLock(false);AscCommon.CollaborativeEditing.Set_GlobalLockSelection(false);if(this.m_fEndLoadCallBack){this.m_fEndLoadCallBack();this.m_fEndLoadCallBack=null}var nPageIndex=undefined;if(this.Is_Fast()){var oParagraph=this.m_oLogicDocument.GetCurrentParagraph();nPageIndex=oParagraph?Math.max(oParagraph.GetCurrentPageAbsolute(),editor.GetCurrentVisiblePage()):undefined}this.m_oLogicDocument.ResumeRecalculate();this.m_oLogicDocument.RecalculateByChanges(this.m_aAllChanges,
|
||||
this.m_nRecalcIndexStart,this.m_nRecalcIndexEnd,false,nPageIndex);this.m_oLogicDocument.UpdateTracks();var oform=this.m_oLogicDocument.GetOFormDocument();if(oform)oform.onEndLoadChanges();editor.sync_EndAction(Asc.c_oAscAsyncActionType.BlockInteraction,Asc.c_oAscAsyncAction.ApplyChanges)};CWordCollaborativeEditing.prototype.Check_MergeData=function(){var LogicDocument=editor.WordControl.m_oLogicDocument;LogicDocument.Comments.Check_MergeData()};
|
||||
this.m_nRecalcIndexStart,this.m_nRecalcIndexEnd,false,nPageIndex);this.m_oLogicDocument.UpdateTracks();if(this.m_oLogicDocument.GetOFormDocument){var oform=this.m_oLogicDocument.GetOFormDocument();if(oform)oform.onEndLoadChanges()}editor.sync_EndAction(Asc.c_oAscAsyncActionType.BlockInteraction,Asc.c_oAscAsyncAction.ApplyChanges)};CWordCollaborativeEditing.prototype.Check_MergeData=function(){var LogicDocument=editor.WordControl.m_oLogicDocument;LogicDocument.Comments.Check_MergeData()};
|
||||
CWordCollaborativeEditing.prototype.OnEnd_CheckLock=function(isDontLockInFastMode,fCallback){var aIds=[];for(var nIndex=0,nCount=this.m_aCheckLocks.length;nIndex<nCount;++nIndex){var oItem=this.m_aCheckLocks[nIndex];if(true===oItem){if(fCallback)fCallback(true);return true}else if(false!==oItem)aIds.push(oItem)}if(true===isDontLockInFastMode&&true===this.Is_Fast())if(fCallback){fCallback(false);return true}else return false;if(fCallback){if(aIds.length>0){var oThis=this;editor.CoAuthoringApi.askLock(aIds,
|
||||
function(result){oThis.Set_GlobalLock(false);if(result["lock"]){oThis.private_LockByMe();fCallback(false)}else if(result["error"])fCallback(true)});this.Set_GlobalLock(true)}else fCallback(false);return true}else{if(aIds.length>0){editor.CoAuthoringApi.askLock(aIds,this.OnCallback_AskLock);if(-1===this.m_nUseType)this.Set_GlobalLock(true);else{this.private_LockByMe();this.m_aCheckLocks.length=0}}return false}};
|
||||
CWordCollaborativeEditing.prototype.private_LockByMe=function(){for(var nIndex=0,nCount=this.m_aCheckLocks.length;nIndex<nCount;++nIndex){var oItem=this.m_aCheckLocks[nIndex];if(true!==oItem&&false!==oItem){var oClass=AscCommon.g_oTableId.Get_ById(oItem);if(oClass)if(oClass.Lock){oClass.Lock.Set_Type(AscCommon.locktype_Mine);this.Add_Unlock2(oClass)}}}};
|
||||
|
||||
Loading…
Reference in New Issue
Block a user