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

Side by Side Diff: third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp

Issue 1852183002: Don't apply svg viewport clip when mapping a LayoutSVGRoot's own rect (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: CORE_EXPORT LayoutSVGRoot Created 4 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/layout/PaintInvalidationState.h" 5 #include "core/layout/PaintInvalidationState.h"
6 6
7 #include "core/frame/FrameView.h" 7 #include "core/frame/FrameView.h"
8 #include "core/frame/Settings.h" 8 #include "core/frame/Settings.h"
9 #include "core/layout/LayoutInline.h" 9 #include "core/layout/LayoutInline.h"
10 #include "core/layout/LayoutPart.h" 10 #include "core/layout/LayoutPart.h"
(...skipping 306 matching lines...) Expand 10 before | Expand all | Expand 10 after
317 317
318 if (m_paintInvalidationContainer.layer()->groupedMapping()) 318 if (m_paintInvalidationContainer.layer()->groupedMapping())
319 PaintLayer::mapRectInPaintInvalidationContainerToBacking(m_paintInvalida tionContainer, rect); 319 PaintLayer::mapRectInPaintInvalidationContainerToBacking(m_paintInvalida tionContainer, rect);
320 return rect; 320 return rect;
321 } 321 }
322 322
323 static void slowMapToVisualRectInAncestorSpace(const LayoutObject& object, const LayoutBoxModelObject& ancestor, LayoutRect& rect) 323 static void slowMapToVisualRectInAncestorSpace(const LayoutObject& object, const LayoutBoxModelObject& ancestor, LayoutRect& rect)
324 { 324 {
325 if (object.isLayoutView()) { 325 if (object.isLayoutView()) {
326 toLayoutView(object).mapToVisualRectInAncestorSpace(&ancestor, rect, Inp utIsInFrameCoordinates, DefaultVisualRectFlags); 326 toLayoutView(object).mapToVisualRectInAncestorSpace(&ancestor, rect, Inp utIsInFrameCoordinates, DefaultVisualRectFlags);
327 } else if (object.isSVGRoot()) {
328 // TODO(crbug.com/597813): This is to avoid the extra clip applied in La youtSVGRoot::mapVisibleRectInAncestorSpace().
329 toLayoutSVGRoot(object).LayoutReplaced::mapToVisualRectInAncestorSpace(& ancestor, rect);
330 } else { 327 } else {
331 object.mapToVisualRectInAncestorSpace(&ancestor, rect); 328 object.mapToVisualRectInAncestorSpace(&ancestor, rect);
332 } 329 }
333 } 330 }
334 331
335 void PaintInvalidationState::mapLocalRectToPaintInvalidationBacking(LayoutRect& rect) const 332 void PaintInvalidationState::mapLocalRectToPaintInvalidationBacking(LayoutRect& rect) const
336 { 333 {
337 ASSERT(!m_didUpdateForChildren); 334 ASSERT(!m_didUpdateForChildren);
338 335
339 if (m_cachedOffsetsEnabled) { 336 if (m_cachedOffsetsEnabled) {
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 369
373 PaintLayer& PaintInvalidationState::enclosingSelfPaintingLayer(const LayoutObjec t& layoutObject) const 370 PaintLayer& PaintInvalidationState::enclosingSelfPaintingLayer(const LayoutObjec t& layoutObject) const
374 { 371 {
375 if (layoutObject.hasLayer() && toLayoutBoxModelObject(layoutObject).hasSelfP aintingLayer()) 372 if (layoutObject.hasLayer() && toLayoutBoxModelObject(layoutObject).hasSelfP aintingLayer())
376 return *toLayoutBoxModelObject(layoutObject).layer(); 373 return *toLayoutBoxModelObject(layoutObject).layer();
377 374
378 return m_enclosingSelfPaintingLayer; 375 return m_enclosingSelfPaintingLayer;
379 } 376 }
380 377
381 } // namespace blink 378 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/core.gypi ('k') | third_party/WebKit/Source/core/layout/svg/LayoutSVGRoot.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698