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

скролл графики с клавы

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@53343 954022d7-b5bf-4e40-9824-e11837661b57
parent cf3789d1
......@@ -3428,7 +3428,33 @@ function DrawingObjects() {
}
}
}
shapeOverlayCtx.updatedRect = null;
if ( bRedraw ) {
var offsetX = worksheet.cols[worksheet.visibleRange.c1].left - worksheet.cellsLeft;
var offsetY = worksheet.rows[worksheet.visibleRange.r1].top - worksheet.cellsTop;
if ( !worksheet.cols[selection.c2 + 1] )
worksheet.expandColsOnScroll(true);
if ( !worksheet.rows[selection.r2 + 1] )
worksheet.expandRowsOnScroll(true);
var x1 = worksheet.cols[selection.c1].left - offsetX;
var y1 = worksheet.rows[selection.r1].top - offsetY;
var x2 = worksheet.cols[selection.c2 + 1].left - offsetX;
var y2 = worksheet.rows[selection.r2 + 1].top - offsetY;
var w = x2 - x1;
var h = y2 - y1;
var updatedRect = { x: 0, y: 0, w: 0, h: 0 };
updatedRect.x = ptToMm(x1) - pxToMm(scrollOffset.getX());
updatedRect.y = ptToMm(y1) - pxToMm(scrollOffset.getY());
updatedRect.w = ptToMm(w);
updatedRect.h = ptToMm(h);
shapeOverlayCtx.updatedRect = updatedRect;
shapeOverlayCtx.ClearMode = true;
for ( var i = 0; i < aObjects.length; i++ ) {
aObjects[i].graphicObject.draw(shapeOverlayCtx);
......
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