Closed Bug 1682754 Opened 5 years ago Closed 5 years ago

Use setPointerCapture in Draggable.js

Categories

(DevTools :: Shared Components, task)

task

Tracking

(firefox86 fixed)

RESOLVED FIXED
86 Branch
Tracking Status
firefox86 --- fixed

People

(Reporter: nchevobbe, Assigned: nchevobbe)

References

Details

Attachments

(1 file)

In draggable, we set a mousemove event on the document once the drag started, in order to keep track of mouse movements, even those "outside" of the drag element.
There's now a dedicated API for that, setPointerCapture, so let's use it instead.

We used to set the mousemove event listener on the document once the drag
started, so we could track mouse movement outside of the drag element.
This can now be done another way, using setPointerCapture, so we can have the
event listener directly on the element, and not on the document anymore.

A few tests that were dispatching mousemove events from the document are updated.

Pushed by nchevobbe@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/cdc175887602 [devtools] Use setPointerCapture in Draggable.js . r=rcaliman.
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → 86 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: