Commit 747fccd6 authored by Igor.Zotov's avatar Igor.Zotov Committed by Alexander.Trofimov

правка для бага №20636 ([Copy&Paste] Текст копируется со 2-ого раза в строке формул на Mac)

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@50670 954022d7-b5bf-4e40-9824-e11837661b57
parent 36631b30
......@@ -2783,18 +2783,22 @@ function Editor_CopyPaste_Create(api)
};
ElemToSelect["onbeforecopy"] = function(e){
api.wb.clipboard.copyRange(api.wb.getWorksheet().getSelectedRange(), api.wb.getWorksheet());
if(!api.isCellEdited)
api.wb.clipboard.copyRange(api.wb.getWorksheet().getSelectedRange(), api.wb.getWorksheet());
};
ElemToSelect["onbeforecut"] = function(e){
api.wb.clipboard.copyRange(api.wb.getWorksheet().getSelectedRange(), api.wb.getWorksheet());
if(isNeedEmptyAfterCut)
if(!api.isCellEdited)
{
isNeedEmptyAfterCut = false;
api.wb.getWorksheet().setSelectionInfo("empty", c_oAscCleanOptions.All);
api.wb.clipboard.copyRange(api.wb.getWorksheet().getSelectedRange(), api.wb.getWorksheet());
if(isNeedEmptyAfterCut)
{
isNeedEmptyAfterCut = false;
api.wb.getWorksheet().setSelectionInfo("empty", c_oAscCleanOptions.All);
}
else
isNeedEmptyAfterCut = true;
}
else
isNeedEmptyAfterCut = true;
};
document.body.appendChild( ElemToSelect );
......@@ -2813,6 +2817,7 @@ function Editor_CopyPaste_Create(api)
elementText.style.zIndex = -1000;
elementText.style.display = ELEMENT_DISPAY_STYLE;
elementText.setAttribute("contentEditable", true);
elementText.setAttribute("class", COPYPASTE_ELEMENT_CLASS);
elementText["onbeforecopy"] = function(e){
if((api.wb && api.wb.getWorksheet() && api.wb.getWorksheet().isCellEditMode))
......
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