[css-scroll-snap] Snapping should align to visual viewport. |
||
Issue descriptionCurrently, snap points only consider the scroll offset of the LayoutViewport(outer viewport scroll layer in cc), ignoring the scroll offset of the VisualViewport(inner viewport scroll layer in cc). This would confuse the user as they enlarge the page. We should make sure snap points align with the visual viewport.
,
May 17 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/5b21b4ef35554c4e5c89dd04be66f011978bdf16 commit 5b21b4ef35554c4e5c89dd04be66f011978bdf16 Author: Sandra Sun <sunyunjia@chromium.org> Date: Thu May 17 23:28:36 2018 Use visual scroll offset for snapping. Currently, snap points only consider the scroll offset of the LayoutViewport(outer viewport scroll layer in cc), ignoring the scroll offset of the VisualViewport(inner viewport scroll layer in cc). This would confuse the user as they enlarge the page. This patch makes sure that the coordinate for snapping is based on visual viewport, and the snapping behavior scrolls visual viewport when necessary. Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;master.tryserver.blink:linux_trusty_blink_rel Change-Id: I29ad271b04ac3fffec733f764e9168bc08150507 Bug: 839971 Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;master.tryserver.blink:linux_trusty_blink_rel Change-Id: I29ad271b04ac3fffec733f764e9168bc08150507 Reviewed-on: https://chromium-review.googlesource.com/1033351 Reviewed-by: Dave Tapuska <dtapuska@chromium.org> Reviewed-by: David Bokan <bokan@chromium.org> Commit-Queue: Sandra Sun <sunyunjia@chromium.org> Cr-Commit-Position: refs/heads/master@{#559729} [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/cc/input/input_handler.h [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/cc/layers/viewport.cc [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/cc/layers/viewport.h [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/cc/trees/layer_tree_host_impl.cc [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/cc/trees/layer_tree_host_impl.h [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/cc/trees/layer_tree_host_impl_unittest.cc [add] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/third_party/WebKit/LayoutTests/fast/scroll-snap/snap-scrolls-visual-viewport.html [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/third_party/blink/renderer/core/frame/root_frame_viewport.cc [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/third_party/blink/renderer/core/frame/root_frame_viewport.h [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/third_party/blink/renderer/core/page/scrolling/snap_coordinator.cc [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/third_party/blink/renderer/platform/scroll/scrollable_area.h [modify] https://crrev.com/5b21b4ef35554c4e5c89dd04be66f011978bdf16/ui/events/blink/input_handler_proxy.cc
,
May 29 2018
|
||
►
Sign in to add a comment |
||
Comment 1 by sunyunjia@chromium.org
, May 7 2018