Commit 88c1f059 authored by Alexander.Trofimov's avatar Alexander.Trofimov Committed by Alexander.Trofimov

Поправил получение координат, если мы вышли за пределы заголовков (для закрепленных областей)

Баг http://bugzserver/show_bug.cgi?id=24227

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@56257 954022d7-b5bf-4e40-9824-e11837661b57
parent 86a5d140
...@@ -5482,6 +5482,13 @@ ...@@ -5482,6 +5482,13 @@
} }
if (!canReturnNull) {return {col: c2, left: this.cols[c2].left - offset, right: x2};} if (!canReturnNull) {return {col: c2, left: this.cols[c2].left - offset, right: x2};}
} else { } else {
if (this.topLeftFrozenCell) {
cFrozen = this.topLeftFrozenCell.getCol0();
if (0 !== cFrozen) {
c = 0;
offset = this.cols[c].left - this.cellsLeft;
}
}
for (x2 = this.cellsLeft + this.cols[c].width, c2 = 0; c >= c2; --c, x2 = x1) { for (x2 = this.cellsLeft + this.cols[c].width, c2 = 0; c >= c2; --c, x2 = x1) {
x1 = this.cols[c].left - offset; x1 = this.cols[c].left - offset;
if (x1 <= x && x < x2) { if (x1 <= x && x < x2) {
...@@ -5539,6 +5546,13 @@ ...@@ -5539,6 +5546,13 @@
} }
if (!canReturnNull) {return {row: r2, top: this.rows[r2].top - offset, bottom: y2};} if (!canReturnNull) {return {row: r2, top: this.rows[r2].top - offset, bottom: y2};}
} else { } else {
if (this.topLeftFrozenCell) {
rFrozen = this.topLeftFrozenCell.getRow0();
if (0 !== rFrozen) {
r = 0;
offset = this.rows[r].top - this.cellsTop;
}
}
for (y2 = this.cellsTop + this.rows[r].height, r2 = 0; r >= r2; --r, y2 = y1) { for (y2 = this.cellsTop + this.rows[r].height, r2 = 0; r >= r2; --r, y2 = y1) {
y1 = this.rows[r].top - offset; y1 = this.rows[r].top - offset;
if (y1 <= y && y < y2) { if (y1 <= y && y < y2) {
......
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