OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/PrePaintTreeWalk.h" | 5 #include "core/paint/PrePaintTreeWalk.h" |
6 | 6 |
7 #include "core/dom/DocumentLifecycle.h" | 7 #include "core/dom/DocumentLifecycle.h" |
8 #include "core/frame/FrameView.h" | 8 #include "core/frame/FrameView.h" |
9 #include "core/frame/LocalFrame.h" | 9 #include "core/frame/LocalFrame.h" |
10 #include "core/layout/LayoutMultiColumnSpannerPlaceholder.h" | 10 #include "core/layout/LayoutMultiColumnSpannerPlaceholder.h" |
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
243 child = child->nextSibling()) { | 243 child = child->nextSibling()) { |
244 if (child->isLayoutMultiColumnSpannerPlaceholder()) { | 244 if (child->isLayoutMultiColumnSpannerPlaceholder()) { |
245 child->getMutableForPainting().clearPaintFlags(); | 245 child->getMutableForPainting().clearPaintFlags(); |
246 continue; | 246 continue; |
247 } | 247 } |
248 walk(*child, context); | 248 walk(*child, context); |
249 } | 249 } |
250 | 250 |
251 if (object.isLayoutPart()) { | 251 if (object.isLayoutPart()) { |
252 const LayoutPart& layoutPart = toLayoutPart(object); | 252 const LayoutPart& layoutPart = toLayoutPart(object); |
253 Widget* widget = layoutPart.widget(); | 253 FrameViewBase* frameViewBase = layoutPart.widget(); |
254 if (widget && widget->isFrameView()) { | 254 if (frameViewBase && frameViewBase->isFrameView()) { |
255 context.treeBuilderContext.current.paintOffset += | 255 context.treeBuilderContext.current.paintOffset += |
256 layoutPart.replacedContentRect().location() - | 256 layoutPart.replacedContentRect().location() - |
257 widget->frameRect().location(); | 257 frameViewBase->frameRect().location(); |
258 context.treeBuilderContext.current.paintOffset = | 258 context.treeBuilderContext.current.paintOffset = |
259 roundedIntPoint(context.treeBuilderContext.current.paintOffset); | 259 roundedIntPoint(context.treeBuilderContext.current.paintOffset); |
260 walk(*toFrameView(widget), context); | 260 walk(*toFrameView(frameViewBase), context); |
261 } | 261 } |
262 // TODO(pdr): Investigate RemoteFrameView (crbug.com/579281). | 262 // TODO(pdr): Investigate RemoteFrameView (crbug.com/579281). |
263 } | 263 } |
264 | 264 |
265 object.getMutableForPainting().clearPaintFlags(); | 265 object.getMutableForPainting().clearPaintFlags(); |
266 } | 266 } |
267 | 267 |
268 } // namespace blink | 268 } // namespace blink |
OLD | NEW |