swh:1:snp:b37d435721bbd450624165f334724e3585346499
Revision eb313d646aff9c95247c506a19f1922f44b267ea authored by Sandra Sun on 19 December 2018, 15:38:18 UTC, committed by Chromium WPT Sync on 19 December 2018, 15:38:18 UTC
As the spec mentions, if the content or layout of the document changes (e.g.
content is added, moved, deleted, resized) such that the content of a snapport
changes, the UA must re-evaluate the resulting scroll position, and re-snap if
required. If the scroll container was snapped before the content change and that
same snap position still exists (e.g. its associated element was not deleted),
the scroll container must be re-snapped to that same snap position after the
content change.

This patch adds SnapForAllContainers() right after UpdateAllSnapContainerData()
during PerformPostLayoutTasks() and adds tests for that.

Some scroll snap tests assume that a scroller's initial scroll position is (0,0)
even with one and only non-zero snap position. This assumption won't hold true
after this change since the scroller would snap at the snap position at the
beginning. So we add an anchor snap element at (0,0) to ensure the scroller
always starts at (0,0) for the tests.

This patch also fixes a bug in VisualViewport::MaximumScrollOffset().
Bug: 866127
Change-Id: Ib050ef91b04d4391a846eda3dbf667e4d412cb08
1 parent 712c9f2
History
Tip revision: 259d0612af038d14f2cd889a14a3adb6c9e96d96 authored by Josh Matthews on 23 December 2018, 05:25:51 UTC
Claim to support testdriver in servodriver
Tip revision: 259d061
File Mode Size
.well-known
2dcontext
BackgroundSync
FileAPI
IndexedDB
WebCryptoAPI
WebIDL
accelerometer
accname
acid
ambient-light
animation-worklet
annotation-model
annotation-protocol
annotation-vocab
apng
appmanifest
async-local-storage
audio-output
background-fetch
battery-status
beacon
bluetooth
clear-site-data
client-hints
clipboard-apis
common
compat
conformance-checkers
console
content-security-policy
cookie-store
cookies
core-aam
cors
credential-management
css
custom-elements
device-memory
docs
dom
domparsing
domxpath
dpub-aam
dpub-aria
editing
encoding
encrypted-media
entries-api
event-timing
eventsource
feature-policy
fetch
fonts
fullscreen
gamepad
generic-sensor
geolocation-API
geolocation-sensor
graphics-aam
gyroscope
hr-time
html
html-longdesc
html-media-capture
imagebitmap-renderingcontext
images
inert
infrastructure
input-device-capabilities
input-events
interfaces
intersection-observer
js
keyboard-lock
keyboard-map
lifecycle
loading
longtask-timing
magnetometer
mathml
media
media-capabilities
media-source
mediacapture-depth
mediacapture-fromelement
mediacapture-image
mediacapture-record
mediacapture-streams
mediasession
mimesniff
mixed-content
mst-content-hint
navigation-timing
netinfo
network-error-logging
notifications
offscreen-canvas
old-tests
orientation-event
orientation-sensor
origin-policy
page-visibility
paint-timing
payment-handler
payment-method-basic-card
payment-method-id
payment-request
performance-timeline
permissions
picture-in-picture
pointerevents
pointerlock
portals
preload
presentation-api
priority-hints
proximity
push-api
quirks
referrer-policy
remote-playback
reporting
requestidlecallback
resize-observer
resource-timing
resources
screen-capture
screen-orientation
scroll-animations
secure-contexts
selection
server-timing
service-workers
shadow-dom
shape-detection
signed-exchange
speech-api
storage
streams
subresource-integrity
svg
svg-aam
tools
touch-events
trusted-types
uievents
upgrade-insecure-requests
url
user-timing
vibration
visual-viewport
wai-aria
wake-lock
wasm
web-animations
web-locks
web-nfc
web-share
webaudio
webauthn
webdriver
webgl
webmessaging
webmidi
webrtc
webrtc-identity
webrtc-quic
webrtc-stats
websockets
webstorage
webusb
webvr
webvtt
webxr
workers
worklets
x-frame-options
xhr
.azure-pipelines.yml -rw-r--r-- 4.8 KB
.codecov.yml -rw-r--r-- 66 bytes
.gitignore -rw-r--r-- 252 bytes
.gitmodules -rw-r--r-- 138 bytes
.pyup.yml -rw-r--r-- 1.1 KB
.taskcluster.yml -rw-r--r-- 6.9 KB
.travis.yml -rw-r--r-- 3.8 KB
CODEOWNERS -rw-r--r-- 98 bytes
CONTRIBUTING.md -rw-r--r-- 1.6 KB
LICENSE.md -rw-r--r-- 5.1 KB
README.md -rw-r--r-- 17.3 KB
check_stability.ini -rw-r--r-- 419 bytes
lint.whitelist -rw-r--r-- 46.1 KB
serve.py -rw-r--r-- 263 bytes
server-side.md -rw-r--r-- 8.1 KB
testharness_runner.html -rw-r--r-- 95 bytes
update-built-tests.sh -rwxr-xr-x 208 bytes
wpt -rwxr-xr-x 95 bytes
wpt.py -rw-r--r-- 15 bytes

README.md

back to top