Skip to content

Commit

Permalink
chore: format
Browse files Browse the repository at this point in the history
  • Loading branch information
BeksOmega committed Sep 29, 2023
1 parent 6d49e54 commit 6d7ec8f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions core/shortcut_items.ts
Original file line number Diff line number Diff line change
Expand Up @@ -191,9 +191,10 @@ export function registerPaste() {
},
callback() {
if (!copyData || !copyCoords || !copyWorkspace) return false;
const {left, top, width, height} =
copyWorkspace.getMetricsManager().getViewMetrics(true);
const viewportRect = new Rect(top, top + height, left, left + width)
const {left, top, width, height} = copyWorkspace
.getMetricsManager()
.getViewMetrics(true);
const viewportRect = new Rect(top, top + height, left, left + width);

if (viewportRect.contains(copyCoords.x, copyCoords.y)) {
// Pass the default copy coordinates when they are inside the viewport.
Expand Down

0 comments on commit 6d7ec8f

Please sign in to comment.