Commit bd05f089 authored by Dmitry.Vikulov's avatar Dmitry.Vikulov Committed by Alexander.Trofimov

Fix critical Bug 20587 - Зависание приложения при перемещении автофигуры

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@50036 954022d7-b5bf-4e40-9824-e11837661b57
parent 87e69d77
...@@ -4219,8 +4219,8 @@ function DrawingObjects() { ...@@ -4219,8 +4219,8 @@ function DrawingObjects() {
var response = { result: true, x: 0, y: 0 }; var response = { result: true, x: 0, y: 0 };
var top = worksheet.getCellTop(0, 3) + pxToMm(1); var top = worksheet.getCellTop(0, 3);
var left = worksheet.getCellLeft(0, 3) + pxToMm(1); var left = worksheet.getCellLeft(0, 3);
// выход за границу слева или сверху // выход за границу слева или сверху
if ( y < 0 ) { if ( y < 0 ) {
...@@ -4233,20 +4233,23 @@ function DrawingObjects() { ...@@ -4233,20 +4233,23 @@ function DrawingObjects() {
} }
// выход за границу справа // выход за границу справа
if ( x + w > left ) {
var foundCol = worksheet._findColUnderCursor(mmToPt(x + w), true); var foundCol = worksheet._findColUnderCursor(mmToPt(x + w), true);
while ( foundCol == null ) { while ( foundCol == null ) {
worksheet.expandColsOnScroll(true); worksheet.expandColsOnScroll(true);
worksheet._trigger("reinitializeScrollX"); worksheet._trigger("reinitializeScrollX");
foundCol = worksheet._findColUnderCursor(mmToPt(x + w), true); foundCol = worksheet._findColUnderCursor(mmToPt(x + w), true);
} }
}
// выход за границу снизу // выход за границу снизу
if ( y + h > top ) {
var foundRow = worksheet._findRowUnderCursor(mmToPt(y + h), true); var foundRow = worksheet._findRowUnderCursor(mmToPt(y + h), true);
while ( foundRow == null ) { while ( foundRow == null ) {
worksheet.expandRowsOnScroll(true); worksheet.expandRowsOnScroll(true);
worksheet._trigger("reinitializeScrollY"); worksheet._trigger("reinitializeScrollY");
foundRow = worksheet._findRowUnderCursor(mmToPt(y + h), true); foundRow = worksheet._findRowUnderCursor(mmToPt(y + h), true);
} }
}
return response; return response;
} }
......
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