Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(263)

Side by Side Diff: third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp

Issue 2825343003: Clean compositing inputs for location APIs for sticky-affected elements. (Closed)
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights
3 * reserved. 3 * reserved.
4 * 4 *
5 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 5 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
6 * 6 *
7 * Other contributors: 7 * Other contributors:
8 * Robert O'Callahan <roc+@cs.cmu.edu> 8 * Robert O'Callahan <roc+@cs.cmu.edu>
9 * David Baron <dbaron@fas.harvard.edu> 9 * David Baron <dbaron@fas.harvard.edu>
10 * Christian Biesinger <cbiesinger@gmail.com> 10 * Christian Biesinger <cbiesinger@gmail.com>
(...skipping 835 matching lines...) Expand 10 before | Expand all | Expand 10 after
846 846
847 ClampScrollOffsetAfterOverflowChange(); 847 ClampScrollOffsetAfterOverflowChange();
848 848
849 if (!scrollbars_are_frozen) { 849 if (!scrollbars_are_frozen) {
850 UpdateScrollableAreaSet(HasScrollableHorizontalOverflow() || 850 UpdateScrollableAreaSet(HasScrollableHorizontalOverflow() ||
851 HasScrollableVerticalOverflow()); 851 HasScrollableVerticalOverflow());
852 } 852 }
853 853
854 DisableCompositingQueryAsserts disabler; 854 DisableCompositingQueryAsserts disabler;
855 PositionOverflowControls(); 855 PositionOverflowControls();
856
857 // Layout of a scrollable area, or any of its descendants (sticky or
858 // otherwise), invalidates the cached sticky constraints.
859 InvalidateAllStickyConstraints();
chrishtr 2017/04/20 17:40:34 This looks like an independent bug. Does it deserv
smcgruer 2017/04/26 14:37:07 Yes, it probably does. Removed the scroll related
856 } 860 }
857 861
858 void PaintLayerScrollableArea::ClampScrollOffsetAfterOverflowChange() { 862 void PaintLayerScrollableArea::ClampScrollOffsetAfterOverflowChange() {
859 // If a vertical scrollbar was removed, the min/max scroll offsets may have 863 // If a vertical scrollbar was removed, the min/max scroll offsets may have
860 // changed, so the scroll offsets needs to be clamped. If the scroll offset 864 // changed, so the scroll offsets needs to be clamped. If the scroll offset
861 // did not change, but the scroll origin *did* change, we still need to notify 865 // did not change, but the scroll origin *did* change, we still need to notify
862 // the scrollbars to update their dimensions. 866 // the scrollbars to update their dimensions.
863 867
864 if (DelayScrollOffsetClampScope::ClampingIsDelayed()) { 868 if (DelayScrollOffsetClampScope::ClampingIsDelayed()) {
865 DelayScrollOffsetClampScope::SetNeedsClamp(this); 869 DelayScrollOffsetClampScope::SetNeedsClamp(this);
(...skipping 1267 matching lines...) Expand 10 before | Expand all | Expand 10 after
2133 2137
2134 void PaintLayerScrollableArea::DelayScrollOffsetClampScope:: 2138 void PaintLayerScrollableArea::DelayScrollOffsetClampScope::
2135 ClampScrollableAreas() { 2139 ClampScrollableAreas() {
2136 for (auto& scrollable_area : *needs_clamp_) 2140 for (auto& scrollable_area : *needs_clamp_)
2137 scrollable_area->ClampScrollOffsetAfterOverflowChange(); 2141 scrollable_area->ClampScrollOffsetAfterOverflowChange();
2138 delete needs_clamp_; 2142 delete needs_clamp_;
2139 needs_clamp_ = nullptr; 2143 needs_clamp_ = nullptr;
2140 } 2144 }
2141 2145
2142 } // namespace blink 2146 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698