mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-04 22:34:53 +08:00
Move getBounding in scrollable case.
This commit is contained in:
parent
1233d876a3
commit
85d4715313
@ -1961,8 +1961,8 @@ class SpineWebComponentOverlay extends HTMLElement implements OverlayAttributes,
|
||||
this.cursorCanvasX = input.x - window.scrollX;
|
||||
this.cursorCanvasY = input.y - window.scrollY;
|
||||
|
||||
const ref = this.parentElement!.getBoundingClientRect();
|
||||
if (this.scrollable) {
|
||||
const ref = this.parentElement!.getBoundingClientRect();
|
||||
this.cursorCanvasX -= ref.left;
|
||||
this.cursorCanvasY -= ref.top;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user