mirror of
https://github.com/zen-browser/desktop.git
synced 2026-01-25 06:06:10 +00:00
fix: Fixed using the wrong window for glance dragging detection, b=no-bug, c=glance
This commit is contained in:
@@ -83,7 +83,7 @@ export class ZenGlanceChild extends JSWindowActorChild {
|
||||
return;
|
||||
}
|
||||
this.#glanceTarget = target;
|
||||
window.addEventListener('mousemove', this.mousemoveCallback, { once: true });
|
||||
this.contentWindow.addEventListener('mousemove', this.mousemoveCallback, { once: true });
|
||||
}
|
||||
|
||||
on_mouseup(event) {
|
||||
@@ -92,8 +92,8 @@ export class ZenGlanceChild extends JSWindowActorChild {
|
||||
event.stopPropagation();
|
||||
this.#openGlance(this.#glanceTarget);
|
||||
this.#glanceTarget = null;
|
||||
window.removeEventListener('mousemove', this.mousemoveCallback);
|
||||
}
|
||||
this.contentWindow.removeEventListener('mousemove', this.mousemoveCallback);
|
||||
}
|
||||
|
||||
mousemoveCallback() {
|
||||
|
||||
Reference in New Issue
Block a user