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

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

Issue 2247543003: Tweak priorities of paint invalidation reasons (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: - Created 4 years, 4 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 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/paint/BoxPaintInvalidator.h" 5 #include "core/paint/BoxPaintInvalidator.h"
6 6
7 #include "core/frame/Settings.h" 7 #include "core/frame/Settings.h"
8 #include "core/layout/LayoutView.h" 8 #include "core/layout/LayoutView.h"
9 #include "core/paint/ObjectPaintInvalidator.h" 9 #include "core/paint/ObjectPaintInvalidator.h"
10 #include "core/paint/PaintInvalidator.h" 10 #include "core/paint/PaintInvalidator.h"
(...skipping 14 matching lines...) Expand all
25 { 25 {
26 DEFINE_STATIC_LOCAL(PreviousBoxSizesMap, map, ()); 26 DEFINE_STATIC_LOCAL(PreviousBoxSizesMap, map, ());
27 return map; 27 return map;
28 } 28 }
29 29
30 void BoxPaintInvalidator::boxWillBeDestroyed(const LayoutBox& box) 30 void BoxPaintInvalidator::boxWillBeDestroyed(const LayoutBox& box)
31 { 31 {
32 previousBoxSizesMap().remove(&box); 32 previousBoxSizesMap().remove(&box);
33 } 33 }
34 34
35 // This is called when ObjectPaintInvalidator already did incremental invalidati on, 35 bool BoxPaintInvalidator::incrementallyInvalidatePaint()
36 // so this function just does what is additionally needed for the LayoutBox.
37 void BoxPaintInvalidator::incrementallyInvalidatePaint()
38 { 36 {
37 bool result = ObjectPaintInvalidator(m_box, m_context).incrementallyInvalida tePaint();
38
39 bool hasBoxDecorations = m_box.styleRef().hasBoxDecorations(); 39 bool hasBoxDecorations = m_box.styleRef().hasBoxDecorations();
40 if (!m_box.styleRef().hasBackground() && !hasBoxDecorations) 40 if (!m_box.styleRef().hasBackground() && !hasBoxDecorations)
41 return; 41 return result;
42 42
43 const LayoutRect& oldBounds = m_context.oldBounds; 43 const LayoutRect& oldBounds = m_context.oldBounds;
44 const LayoutRect& newBounds = m_context.newBounds; 44 const LayoutRect& newBounds = m_context.newBounds;
45 45
46 LayoutSize oldBorderBoxSize = computePreviousBorderBoxSize(oldBounds.size()) ; 46 LayoutSize oldBorderBoxSize = computePreviousBorderBoxSize(oldBounds.size()) ;
47 LayoutSize newBorderBoxSize = m_box.size(); 47 LayoutSize newBorderBoxSize = m_box.size();
48 48
49 // If border m_box size didn't change, LayoutObject's incrementallyInvalidat ePaint() is good. 49 // If border m_box size didn't change, ObjectPaintInvalidator::incrementally InvalidatePaint() is good.
50 if (oldBorderBoxSize == newBorderBoxSize) 50 if (oldBorderBoxSize == newBorderBoxSize)
51 return; 51 return result;
52 52
53 // If size of the paint invalidation rect equals to size of border box, Obje ctPaintInvalidator::incrementallyInvalidatePaint() 53 // If size of the paint invalidation rect equals to size of border box, Obje ctPaintInvalidator::incrementallyInvalidatePaint()
54 // is good for boxes having background without box decorations. 54 // is good for boxes having background without box decorations.
55 DCHECK(oldBounds.location() == newBounds.location()); // Otherwise we won't do incremental invalidation. 55 DCHECK(oldBounds.location() == newBounds.location()); // Otherwise we won't do incremental invalidation.
56 if (!hasBoxDecorations 56 if (!hasBoxDecorations
57 && m_context.newLocation == newBounds.location() 57 && m_context.newLocation == newBounds.location()
58 && oldBorderBoxSize == oldBounds.size() 58 && oldBorderBoxSize == oldBounds.size()
59 && newBorderBoxSize == newBounds.size()) 59 && newBorderBoxSize == newBounds.size())
60 return; 60 return result;
61 61
62 // Invalidate the right delta part and the right border of the old or new m_ box which has smaller width. 62 // Invalidate the right delta part and the right border of the old or new m_ box which has smaller width.
63 if (LayoutUnit deltaWidth = (oldBorderBoxSize.width() - newBorderBoxSize.wid th()).abs()) { 63 if (LayoutUnit deltaWidth = (oldBorderBoxSize.width() - newBorderBoxSize.wid th()).abs()) {
64 LayoutUnit smallerWidth = std::min(oldBorderBoxSize.width(), newBorderBo xSize.width()); 64 LayoutUnit smallerWidth = std::min(oldBorderBoxSize.width(), newBorderBo xSize.width());
65 LayoutUnit borderTopRightRadiusWidth = valueForLength(m_box.styleRef().b orderTopRightRadius().width(), smallerWidth); 65 LayoutUnit borderTopRightRadiusWidth = valueForLength(m_box.styleRef().b orderTopRightRadius().width(), smallerWidth);
66 LayoutUnit borderBottomRightRadiusWidth = valueForLength(m_box.styleRef( ).borderBottomRightRadius().width(), smallerWidth); 66 LayoutUnit borderBottomRightRadiusWidth = valueForLength(m_box.styleRef( ).borderBottomRightRadius().width(), smallerWidth);
67 LayoutUnit borderWidth = std::max(LayoutUnit(m_box.borderRight()), std:: max(borderTopRightRadiusWidth, borderBottomRightRadiusWidth)); 67 LayoutUnit borderWidth = std::max(LayoutUnit(m_box.borderRight()), std:: max(borderTopRightRadiusWidth, borderBottomRightRadiusWidth));
68 LayoutRect rightDeltaRect(m_context.newLocation.x() + smallerWidth - bor derWidth, m_context.newLocation.y(), 68 LayoutRect rightDeltaRect(m_context.newLocation.x() + smallerWidth - bor derWidth, m_context.newLocation.y(),
69 deltaWidth + borderWidth, std::max(oldBorderBoxSize.height(), newBor derBoxSize.height())); 69 deltaWidth + borderWidth, std::max(oldBorderBoxSize.height(), newBor derBoxSize.height()));
70 invalidatePaintRectClippedByOldAndNewBounds(rightDeltaRect); 70 invalidatePaintRectClippedByOldAndNewBounds(rightDeltaRect);
71 } 71 }
72 72
73 // Invalidate the bottom delta part and the bottom border of the old or new m_box which has smaller height. 73 // Invalidate the bottom delta part and the bottom border of the old or new m_box which has smaller height.
74 if (LayoutUnit deltaHeight = (oldBorderBoxSize.height() - newBorderBoxSize.h eight()).abs()) { 74 if (LayoutUnit deltaHeight = (oldBorderBoxSize.height() - newBorderBoxSize.h eight()).abs()) {
75 LayoutUnit smallerHeight = std::min(oldBorderBoxSize.height(), newBorder BoxSize.height()); 75 LayoutUnit smallerHeight = std::min(oldBorderBoxSize.height(), newBorder BoxSize.height());
76 LayoutUnit borderBottomLeftRadiusHeight = valueForLength(m_box.styleRef( ).borderBottomLeftRadius().height(), smallerHeight); 76 LayoutUnit borderBottomLeftRadiusHeight = valueForLength(m_box.styleRef( ).borderBottomLeftRadius().height(), smallerHeight);
77 LayoutUnit borderBottomRightRadiusHeight = valueForLength(m_box.styleRef ().borderBottomRightRadius().height(), smallerHeight); 77 LayoutUnit borderBottomRightRadiusHeight = valueForLength(m_box.styleRef ().borderBottomRightRadius().height(), smallerHeight);
78 LayoutUnit borderHeight = std::max(LayoutUnit(m_box.borderBottom()), std ::max(borderBottomLeftRadiusHeight, borderBottomRightRadiusHeight)); 78 LayoutUnit borderHeight = std::max(LayoutUnit(m_box.borderBottom()), std ::max(borderBottomLeftRadiusHeight, borderBottomRightRadiusHeight));
79 LayoutRect bottomDeltaRect(m_context.newLocation.x(), m_context.newLocat ion.y() + smallerHeight - borderHeight, 79 LayoutRect bottomDeltaRect(m_context.newLocation.x(), m_context.newLocat ion.y() + smallerHeight - borderHeight,
80 std::max(oldBorderBoxSize.width(), newBorderBoxSize.width()), deltaH eight + borderHeight); 80 std::max(oldBorderBoxSize.width(), newBorderBoxSize.width()), deltaH eight + borderHeight);
81 invalidatePaintRectClippedByOldAndNewBounds(bottomDeltaRect); 81 invalidatePaintRectClippedByOldAndNewBounds(bottomDeltaRect);
82 } 82 }
83
84 return true;
83 } 85 }
84 86
85 void BoxPaintInvalidator::invalidatePaintRectClippedByOldAndNewBounds(const Layo utRect& rect) 87 void BoxPaintInvalidator::invalidatePaintRectClippedByOldAndNewBounds(const Layo utRect& rect)
86 { 88 {
87 if (rect.isEmpty()) 89 if (rect.isEmpty())
88 return; 90 return;
89 91
90 LayoutRect rectClippedByOldBounds = intersection(rect, m_context.oldBounds); 92 LayoutRect rectClippedByOldBounds = intersection(rect, m_context.oldBounds);
91 LayoutRect rectClippedByNewBounds = intersection(rect, m_context.newBounds); 93 LayoutRect rectClippedByNewBounds = intersection(rect, m_context.newBounds);
92 // Invalidate only once if the clipped rects equal. 94 // Invalidate only once if the clipped rects equal.
93 if (rectClippedByOldBounds == rectClippedByNewBounds) { 95 if (rectClippedByOldBounds == rectClippedByNewBounds) {
94 m_box.invalidatePaintUsingContainer(*m_context.paintInvalidationContaine r, rectClippedByOldBounds, PaintInvalidationIncremental); 96 m_box.invalidatePaintUsingContainer(*m_context.paintInvalidationContaine r, rectClippedByOldBounds, PaintInvalidationIncremental);
95 return; 97 return;
96 } 98 }
97 // Invalidate the bigger one if one contains another. Otherwise invalidate b oth. 99 // Invalidate the bigger one if one contains another. Otherwise invalidate b oth.
98 if (!rectClippedByNewBounds.contains(rectClippedByOldBounds)) 100 if (!rectClippedByNewBounds.contains(rectClippedByOldBounds))
99 m_box.invalidatePaintUsingContainer(*m_context.paintInvalidationContaine r, rectClippedByOldBounds, PaintInvalidationIncremental); 101 m_box.invalidatePaintUsingContainer(*m_context.paintInvalidationContaine r, rectClippedByOldBounds, PaintInvalidationIncremental);
100 if (!rectClippedByOldBounds.contains(rectClippedByNewBounds)) 102 if (!rectClippedByOldBounds.contains(rectClippedByNewBounds))
101 m_box.invalidatePaintUsingContainer(*m_context.paintInvalidationContaine r, rectClippedByNewBounds, PaintInvalidationIncremental); 103 m_box.invalidatePaintUsingContainer(*m_context.paintInvalidationContaine r, rectClippedByNewBounds, PaintInvalidationIncremental);
102 } 104 }
103 105
104 PaintInvalidationReason BoxPaintInvalidator::computePaintInvalidationReason() 106 PaintInvalidationReason BoxPaintInvalidator::computePaintInvalidationReason()
105 { 107 {
106 PaintInvalidationReason reason = ObjectPaintInvalidator(m_box, m_context).co mputePaintInvalidationReason(); 108 PaintInvalidationReason reason = ObjectPaintInvalidator(m_box, m_context).co mputePaintInvalidationReason();
107 109
108 if (reason != PaintInvalidationDelayedFull && isFullPaintInvalidationReason( reason)) 110 if (isImmediateFullPaintInvalidationReason(reason) || reason == PaintInvalid ationNone)
109 return reason; 111 return reason;
110 112
111 if (m_box.mayNeedPaintInvalidationAnimatedBackgroundImage() && !m_box.backgr oundIsKnownToBeObscured()) 113 if (m_box.mayNeedPaintInvalidationAnimatedBackgroundImage() && !m_box.backgr oundIsKnownToBeObscured())
112 reason = PaintInvalidationDelayedFull; 114 reason = PaintInvalidationDelayedFull;
113 115
114 // If the current paint invalidation reason is PaintInvalidationDelayedFull, then this paint invalidation can delayed if the 116 // If the current paint invalidation reason is PaintInvalidationDelayedFull, then this paint invalidation can delayed if the
115 // LayoutBox in question is not on-screen. The logic to decide whether this is appropriate exists at the site of the original 117 // LayoutBox in question is not on-screen. The logic to decide whether this is appropriate exists at the site of the original
116 // paint invalidation that chose PaintInvalidationDelayedFull. 118 // paint invalidation that chose PaintInvalidationDelayedFull.
117 if (reason == PaintInvalidationDelayedFull) { 119 if (reason == PaintInvalidationDelayedFull) {
118 // Do regular full paint invalidation if the object is onscreen. 120 // Do regular full paint invalidation if the object is onscreen.
119 return m_box.intersectsVisibleViewport() ? PaintInvalidationFull : Paint InvalidationDelayedFull; 121 return m_box.intersectsVisibleViewport() ? PaintInvalidationFull : Paint InvalidationDelayedFull;
120 } 122 }
121 123
122 if (m_box.isLayoutView()) { 124 if (m_box.isLayoutView()) {
123 const LayoutView& layoutView = toLayoutView(m_box); 125 const LayoutView& layoutView = toLayoutView(m_box);
124 // In normal compositing mode, root background doesn't need to be invali dated for 126 // In normal compositing mode, root background doesn't need to be invali dated for
125 // box changes, because the background always covers the whole document rect 127 // box changes, because the background always covers the whole document rect
126 // and clipping is done by compositor()->m_containerLayer. Also the scro llbars 128 // and clipping is done by compositor()->m_containerLayer. Also the scro llbars
127 // are always composited. There are no other box decoration on the Layou tView thus 129 // are always composited. There are no other box decoration on the Layou tView thus
128 // we can safely exit here. 130 // we can safely exit here.
129 if (layoutView.usesCompositing() && (!layoutView.document().settings() | | !layoutView.document().settings()->rootLayerScrolls())) 131 if (layoutView.usesCompositing() && (!layoutView.document().settings() | | !layoutView.document().settings()->rootLayerScrolls()))
130 return reason; 132 return reason;
131 } 133 }
132 134
133 // If the transform is not identity or translation, incremental invalidation is not applicable 135 // If the transform is not identity or translation, incremental invalidation is not applicable
134 // because the difference between oldBounds and newBounds doesn't cover all area needing invalidation. 136 // because the difference between oldBounds and newBounds doesn't cover all area needing invalidation.
135 // FIXME: Should also consider ancestor transforms since paintInvalidationCo ntainer. crbug.com/426111. 137 // FIXME: Should also consider ancestor transforms since paintInvalidationCo ntainer. crbug.com/426111.
136 if (reason == PaintInvalidationIncremental 138 if (reason == PaintInvalidationIncremental
139 && m_context.oldBounds != m_context.newBounds
137 && m_context.paintInvalidationContainer != m_box 140 && m_context.paintInvalidationContainer != m_box
138 && m_box.hasLayer() && m_box.layer()->transform() 141 && m_box.hasLayer() && m_box.layer()->transform()
139 && !m_box.layer()->transform()->isIdentityOrTranslation()) 142 && !m_box.layer()->transform()->isIdentityOrTranslation())
140 return PaintInvalidationBoundsChange; 143 return PaintInvalidationBoundsChange;
141 144
142 const ComputedStyle& style = m_box.styleRef(); 145 const ComputedStyle& style = m_box.styleRef();
143 if (style.backgroundLayers().thisOrNextLayersUseContentBox() || style.maskLa yers().thisOrNextLayersUseContentBox() || style.boxSizing() == BoxSizingBorderBo x) { 146 if (style.backgroundLayers().thisOrNextLayersUseContentBox() || style.maskLa yers().thisOrNextLayersUseContentBox() || style.boxSizing() == BoxSizingBorderBo x) {
144 if (previousBoxSizesMap().get(&m_box).contentBoxRect != m_box.contentBox Rect()) 147 if (previousBoxSizesMap().get(&m_box).contentBoxRect != m_box.contentBox Rect())
145 return PaintInvalidationContentBoxChange; 148 return PaintInvalidationContentBoxChange;
146 } 149 }
147 150
148 if (!style.hasBackground() && !style.hasBoxDecorations()) { 151 if (!style.hasBackground() && !style.hasBoxDecorations()) {
149 // We could let incremental invalidation cover non-composited scrollbars , but just 152 // We could let incremental invalidation cover non-composited scrollbars , but just
150 // do a full invalidation because incremental invalidation will go away with slimming paint. 153 // do a full invalidation because incremental invalidation will go away with slimming paint.
151 if (reason == PaintInvalidationIncremental && m_box.hasNonCompositedScro llbars()) 154 if (reason == PaintInvalidationIncremental && m_context.oldBounds != m_c ontext.newBounds && m_box.hasNonCompositedScrollbars())
152 return PaintInvalidationBorderBoxChange; 155 return PaintInvalidationBorderBoxChange;
153 return reason; 156 return reason;
154 } 157 }
155 158
156 if (style.backgroundLayers().thisOrNextLayersHaveLocalAttachment()) { 159 if (style.backgroundLayers().thisOrNextLayersHaveLocalAttachment()) {
157 if (previousBoxSizesMap().get(&m_box).layoutOverflowRect != m_box.layout OverflowRect()) 160 if (previousBoxSizesMap().get(&m_box).layoutOverflowRect != m_box.layout OverflowRect())
158 return PaintInvalidationLayoutOverflowBoxChange; 161 return PaintInvalidationLayoutOverflowBoxChange;
159 } 162 }
160 163
161 LayoutSize oldBorderBoxSize = computePreviousBorderBoxSize(m_context.oldBoun ds.size()); 164 LayoutSize oldBorderBoxSize = computePreviousBorderBoxSize(m_context.oldBoun ds.size());
162 LayoutSize newBorderBoxSize = m_box.size(); 165 LayoutSize newBorderBoxSize = m_box.size();
163 166
164 if (oldBorderBoxSize == newBorderBoxSize) 167 if (oldBorderBoxSize == newBorderBoxSize)
165 return reason; 168 return reason;
166 169
167 // LayoutBox::incrementallyInvalidatePaint() depends on positionFromPaintInv alidationBacking
168 // which is not available when slimmingPaintOffsetCachingEnabled.
169 if (RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled() && (style.has BoxDecorations() || style.hasBackground()))
170 return PaintInvalidationBorderBoxChange;
171
172 // See another hasNonCompositedScrollbars() callsite above. 170 // See another hasNonCompositedScrollbars() callsite above.
173 if (m_box.hasNonCompositedScrollbars()) 171 if (m_box.hasNonCompositedScrollbars())
174 return PaintInvalidationBorderBoxChange; 172 return PaintInvalidationBorderBoxChange;
175 173
176 if (style.hasVisualOverflowingEffect() || style.hasAppearance() || style.has FilterInducingProperty() || style.resize() != RESIZE_NONE) 174 if (style.hasVisualOverflowingEffect() || style.hasAppearance() || style.has FilterInducingProperty() || style.resize() != RESIZE_NONE)
177 return PaintInvalidationBorderBoxChange; 175 return PaintInvalidationBorderBoxChange;
178 176
179 if (style.hasBorderRadius()) { 177 if (style.hasBorderRadius()) {
180 // If a border-radius exists and width/height is smaller than radius wid th/height, 178 // If a border-radius exists and width/height is smaller than radius wid th/height,
181 // we need to fully invalidate to cover the changed radius. 179 // we need to fully invalidate to cover the changed radius.
182 FloatRoundedRect oldRoundedRect = style.getRoundedBorderFor(LayoutRect(L ayoutPoint(0, 0), oldBorderBoxSize)); 180 FloatRoundedRect oldRoundedRect = style.getRoundedBorderFor(LayoutRect(L ayoutPoint(0, 0), oldBorderBoxSize));
183 FloatRoundedRect newRoundedRect = style.getRoundedBorderFor(LayoutRect(L ayoutPoint(0, 0), newBorderBoxSize)); 181 FloatRoundedRect newRoundedRect = style.getRoundedBorderFor(LayoutRect(L ayoutPoint(0, 0), newBorderBoxSize));
184 if (oldRoundedRect.getRadii() != newRoundedRect.getRadii()) 182 if (oldRoundedRect.getRadii() != newRoundedRect.getRadii())
185 return PaintInvalidationBorderBoxChange; 183 return PaintInvalidationBorderBoxChange;
186 } 184 }
187 185
188 if (oldBorderBoxSize.width() != newBorderBoxSize.width() && m_box.mustInvali dateBackgroundOrBorderPaintOnWidthChange()) 186 if (oldBorderBoxSize.width() != newBorderBoxSize.width() && m_box.mustInvali dateBackgroundOrBorderPaintOnWidthChange())
189 return PaintInvalidationBorderBoxChange; 187 return PaintInvalidationBorderBoxChange;
190 if (oldBorderBoxSize.height() != newBorderBoxSize.height() && m_box.mustInva lidateBackgroundOrBorderPaintOnHeightChange()) 188 if (oldBorderBoxSize.height() != newBorderBoxSize.height() && m_box.mustInva lidateBackgroundOrBorderPaintOnHeightChange())
191 return PaintInvalidationBorderBoxChange; 189 return PaintInvalidationBorderBoxChange;
192 190
193 if (reason == PaintInvalidationNone && (style.hasBackground() || style.hasBo xDecorations()))
194 reason = PaintInvalidationIncremental;
195
196 return reason; 191 return reason;
197 } 192 }
198 193
199 PaintInvalidationReason BoxPaintInvalidator::invalidatePaintIfNeeded() 194 PaintInvalidationReason BoxPaintInvalidator::invalidatePaintIfNeeded()
200 { 195 {
201 PaintInvalidationReason reason = ObjectPaintInvalidator(m_box, m_context).in validatePaintIfNeededWithComputedReason(computePaintInvalidationReason()); 196 PaintInvalidationReason reason = computePaintInvalidationReason();
202 197 if (reason == PaintInvalidationIncremental) {
203 // For incremental invalidation, ObjectPaintInvalidator::incrementallyInvali datePaint() is 198 if (incrementallyInvalidatePaint()) {
204 // not enough for LayoutBox in some cases, e.g. having border, border-radius , etc. 199 m_context.paintingLayer->setNeedsRepaint();
205 // The following will do additional incremental invalidation for LayoutBox i f needed. 200 m_box.invalidateDisplayItemClients(reason);
206 if (reason == PaintInvalidationIncremental) 201 } else {
207 incrementallyInvalidatePaint(); 202 reason = PaintInvalidationNone;
203 }
204 // Though we have done our own version of incremental invalidation, we s till need to call
205 // ObjectPaintInvalidator with PaintInvalidationNone to do any other req uired operations.
206 reason = std::max(reason, ObjectPaintInvalidator(m_box, m_context).inval idatePaintIfNeededWithComputedReason(PaintInvalidationNone));
207 } else {
208 reason = ObjectPaintInvalidator(m_box, m_context).invalidatePaintIfNeede dWithComputedReason(reason);
209 }
208 210
209 if (PaintLayerScrollableArea* area = m_box.getScrollableArea()) 211 if (PaintLayerScrollableArea* area = m_box.getScrollableArea())
210 area->invalidatePaintOfScrollControlsIfNeeded(m_context); 212 area->invalidatePaintOfScrollControlsIfNeeded(m_context);
211 213
212 // This is for the next invalidatePaintIfNeeded so must be at the end. 214 // This is for the next invalidatePaintIfNeeded so must be at the end.
213 savePreviousBoxSizesIfNeeded(); 215 savePreviousBoxSizesIfNeeded();
214 216
215 return reason; 217 return reason;
216 } 218 }
217 219
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 271
270 auto it = previousBoxSizesMap().find(&m_box); 272 auto it = previousBoxSizesMap().find(&m_box);
271 if (it != previousBoxSizesMap().end()) 273 if (it != previousBoxSizesMap().end())
272 return it->value.borderBoxSize; 274 return it->value.borderBoxSize;
273 275
274 // We didn't save the old border box size because it was the same as the siz e of oldBounds. 276 // We didn't save the old border box size because it was the same as the siz e of oldBounds.
275 return previousBoundsSize; 277 return previousBoundsSize;
276 } 278 }
277 279
278 } // namespace blink 280 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698