Commit 5aaeac16 authored by Igor.Zotov's avatar Igor.Zotov Committed by Alexander.Trofimov

http://bugzserver/show_bug.cgi?id=27901 - Не происходит возникновения окна с...

http://bugzserver/show_bug.cgi?id=27901 - Не происходит возникновения окна с ошибкой при copy&paste всей строки, ячейки которой объединены

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@65060 954022d7-b5bf-4e40-9824-e11837661b57
parent 469bc2be
......@@ -54,7 +54,9 @@ var c_oAscError = {
AutoFilterDataRangeError: -50,
AutoFilterChangeFormatTableError: -51,
AutoFilterChangeError: -52,
PasteMaxRangeError: - 65,
MaxDataSeriesError: -80,
CannotFillRange: -81,
......
......@@ -1764,12 +1764,16 @@
}
}
}
else {
var newFonts = {};
pasteData.generateFontMap(newFonts);
worksheet._loadFonts(newFonts, function() {
worksheet.setSelectionInfo('paste', pasteData, false, "binary");
});
else
{
if(this._checkPasteFromBinaryExcel(worksheet, true))
{
var newFonts = {};
pasteData.generateFontMap(newFonts);
worksheet._loadFonts(newFonts, function() {
worksheet.setSelectionInfo('paste', pasteData, false, "binary");
});
}
}
return true;
......@@ -1857,6 +1861,22 @@
return false;
},
_checkPasteFromBinaryExcel: function(worksheet, isWriteError)
{
var activeCellsPasteFragment = Asc.g_oRangeCache.getAscRange(this.activeRange);
var rMax = (activeCellsPasteFragment.r2 - activeCellsPasteFragment.r1) + worksheet.activeRange.r1;
var cMax = (activeCellsPasteFragment.c2 - activeCellsPasteFragment.c1) + worksheet.activeRange.c1;
//если область вставки выходит за пределы доступной области
if(cMax > gc_nMaxCol0 || rMax > gc_nMaxRow0)
{
if(isWriteError)
worksheet.handlers.trigger ("onErrorEvent", c_oAscError.ID.PasteMaxRangeError, c_oAscError.Level.NoCritical);
return false;
}
return true;
},
_getClassBinaryFromHtml: function(node)
{
var classNode, base64 = null, base64FromWord = null, base64FromPresentation = null;
......
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