Differentiate scroll operations (which will be asynchronously running by APZ) triggered by script
Categories
(Core :: Panning and Zooming, enhancement)
Tracking
()
Tracking | Status | |
---|---|---|
firefox96 | --- | fixed |
People
(Reporter: hiro, Assigned: hiro)
References
Details
Attachments
(8 files)
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review |
The changes for bug 1692708 have been bigger than I thought initially because I also have some minor cleanups, so I'd like to handle these changes in this individual bug. These change should not impact any user interactions.
The target scroll operations are;
Element.scroll()s, Element.scrollTo()s, Element.scrollBy()s, Element.scrollTop, Elemenet.scrollLeft and Element.scrollIntoView. Also Window.scroll()s, Window.scrollTo()s and Window.scrollBy()s.
Either Window.scrollByLines or Window.scrollByPages are not in the scope. They are moz extensions, just basically used in our xul tree implementation.
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Comment 1•3 years ago
|
||
All call sites of ScrollByCSSPixels specify ScrollOrigin::Relative.
Assignee | ||
Comment 2•3 years ago
|
||
There are 4 call sites of the function, Element::Scroll, Element::SetScrollTop,
Element::SetScrollLeft and nsGlobalWindowInner::ScrollTo. None of call sites
specifies ScrollOrigin.
Depends on D130415
Assignee | ||
Comment 3•3 years ago
|
||
Depends on D130416
Assignee | ||
Comment 4•3 years ago
|
||
Both ScrollToCSSPixels and ScrollByCSSPixels are called only from JS via
Element.scrollTo, Element.scrollTop, Element.scrollLeft, Window.scroll,
Window.scrollTo and Window.scrollBy.
Note that we don't target either Window.scrollByLines or Window.scrollByPages
(both end up calling ScrollFrameHelper::ScrollBy) because both are triggered by
user interactions for our XUL tree implementation, for example
Window.scrollByLines gets called in response to a DOMMouseScroll event in
tree.js [1].
Depends on D130417
Assignee | ||
Comment 5•3 years ago
|
||
We'd want to differentiate Element.scrollIntoView call as triggeredByScript
.
Depends on D130418
Assignee | ||
Comment 6•3 years ago
|
||
Depends on D130419
Assignee | ||
Comment 7•3 years ago
|
||
Depends on D130420
Assignee | ||
Comment 8•3 years ago
|
||
Depends on D130420
Pushed by hikezoe.birchill@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/21ff7d9ba6df Drop ScrollOrigin argument from ScrollByCSSPixels. r=botond https://hg.mozilla.org/integration/autoland/rev/5420b6c278b5 Drop ScrollOrigin argument from ScrollToCSSPixels. r=botond https://hg.mozilla.org/integration/autoland/rev/19252a004ff3 Drop `e` prefix from ScrollMode comments. r=botond https://hg.mozilla.org/integration/autoland/rev/dcfcbfd27ea5 Introduce TriggeredByScript in ScrollPositionUpdate and set `Yes` for ScrollToCSSPixels and ScrollByCSSPixels. r=botond https://hg.mozilla.org/integration/autoland/rev/981eef98a585 Set `TriggerByScript::Yes` for Element.scrollIntoView. r=botond https://hg.mozilla.org/integration/autoland/rev/4c0fdefcf0a0 Introduce WasTriggeedByScript() function in AsyncPanZoomAnimation class. r=botond https://hg.mozilla.org/integration/autoland/rev/1288f0879002 Use `using` instead of `typedef` in nsGfxScrollFrame.h. r=botond https://hg.mozilla.org/integration/autoland/rev/bfd44deda9c7 Introduce APZScrollAnimationType and use it in RepaintRequest and ScrollFrameHelopr instead of a boolean representing whether there's an animation or not. r=botond
Comment 10•3 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/21ff7d9ba6df
https://hg.mozilla.org/mozilla-central/rev/5420b6c278b5
https://hg.mozilla.org/mozilla-central/rev/19252a004ff3
https://hg.mozilla.org/mozilla-central/rev/dcfcbfd27ea5
https://hg.mozilla.org/mozilla-central/rev/981eef98a585
https://hg.mozilla.org/mozilla-central/rev/4c0fdefcf0a0
https://hg.mozilla.org/mozilla-central/rev/1288f0879002
https://hg.mozilla.org/mozilla-central/rev/bfd44deda9c7
Description
•