Skip to content

Commit

Permalink
[se] By bug 58693 (#2958)
Browse files Browse the repository at this point in the history
* [se] Fix bug 58693
  • Loading branch information
GoshaZotov authored Aug 30, 2022
1 parent 04bc622 commit 0c37e8a
Showing 1 changed file with 17 additions and 17 deletions.
34 changes: 17 additions & 17 deletions cell/view/WorksheetView.js
Original file line number Diff line number Diff line change
Expand Up @@ -8952,23 +8952,23 @@
userIdAllProps = isLocked.UserId;
}
}
//проверяем, не попали ли мы в чужой селект
if (this.collaborativeEditing.getFast()) {
var isForeignSelect = this.collaborativeEditing.getForeignSelectIntersection(c.col, r.row);
if (isForeignSelect) {
var foreignRow = isForeignSelect.ranges[0].r1;
var foreignCol = isForeignSelect.ranges[0].c2;
userIdForeignSelect = isForeignSelect.userId;
shortIdForeignSelect = isForeignSelect.shortId;
foreignSelectPosLeft = this._getColLeft(foreignCol) + this._getColumnWidth(foreignCol);
foreignSelectPosTop = this._getRowTop(foreignRow);
// Пересчитываем X и Y относительно видимой области
foreignSelectPosLeft -= offsetX;
foreignSelectPosTop -= offsetY;
foreignSelectPosLeft = this.cellsLeft > foreignSelectPosLeft ? this.cellsLeft : foreignSelectPosLeft;
foreignSelectPosTop = this.cellsTop > foreignSelectPosTop ? this.cellsTop : foreignSelectPosTop;
}
}

//проверяем, не попали ли мы в чужой селект
if (((canEdit && this.collaborativeEditing.getCollaborativeEditing()) || this.workbook.Api.isLiveViewer()) && readyMode && this.collaborativeEditing.getFast()) {
var isForeignSelect = this.collaborativeEditing.getForeignSelectIntersection(c.col, r.row);
if (isForeignSelect) {
var foreignRow = isForeignSelect.ranges[0].r1;
var foreignCol = isForeignSelect.ranges[0].c2;
userIdForeignSelect = isForeignSelect.userId;
shortIdForeignSelect = isForeignSelect.shortId;
foreignSelectPosLeft = this._getColLeft(foreignCol) + this._getColumnWidth(foreignCol);
foreignSelectPosTop = this._getRowTop(foreignRow);
// Пересчитываем X и Y относительно видимой области
foreignSelectPosLeft -= offsetX;
foreignSelectPosTop -= offsetY;
foreignSelectPosLeft = this.cellsLeft > foreignSelectPosLeft ? this.cellsLeft : foreignSelectPosLeft;
foreignSelectPosTop = this.cellsTop > foreignSelectPosTop ? this.cellsTop : foreignSelectPosTop;
}
}

Expand Down

0 comments on commit 0c37e8a

Please sign in to comment.