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

Side by Side Diff: third_party/WebKit/Source/core/layout/svg/SVGLayoutSupport.h

Issue 1747223002: Implement mapAncestorToLocal for LayoutSVG{ModelObject,Block} (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add ASSERT for expected types Created 4 years, 9 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) 2007 Rob Buis <buis@kde.org> 2 * Copyright (C) 2007 Rob Buis <buis@kde.org>
3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> 3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org>
4 * Copyright (C) 2007 Eric Seidel <eric@webkit.org> 4 * Copyright (C) 2007 Eric Seidel <eric@webkit.org>
5 * Copyright (C) 2009 Google, Inc. All rights reserved. 5 * Copyright (C) 2009 Google, Inc. All rights reserved.
6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 74
75 static void computeContainerBoundingBoxes(const LayoutObject* container, Flo atRect& objectBoundingBox, bool& objectBoundingBoxValid, FloatRect& strokeBoundi ngBox, FloatRect& paintInvalidationBoundingBox); 75 static void computeContainerBoundingBoxes(const LayoutObject* container, Flo atRect& objectBoundingBox, bool& objectBoundingBoxValid, FloatRect& strokeBoundi ngBox, FloatRect& paintInvalidationBoundingBox);
76 76
77 // Important functions used by nearly all SVG layoutObjects centralizing coo rdinate transformations / paint invalidation rect calculations 77 // Important functions used by nearly all SVG layoutObjects centralizing coo rdinate transformations / paint invalidation rect calculations
78 static LayoutRect clippedOverflowRectForPaintInvalidation(const LayoutObject &, 78 static LayoutRect clippedOverflowRectForPaintInvalidation(const LayoutObject &,
79 const LayoutBoxModelObject* paintInvalidationContainer, const PaintInval idationState*, 79 const LayoutBoxModelObject* paintInvalidationContainer, const PaintInval idationState*,
80 float strokeWidthForHairlinePadding = 0); 80 float strokeWidthForHairlinePadding = 0);
81 static const LayoutSVGRoot& mapRectToSVGRootForPaintInvalidation(const Layou tObject&, 81 static const LayoutSVGRoot& mapRectToSVGRootForPaintInvalidation(const Layou tObject&,
82 const FloatRect& localPaintInvalidationRect, LayoutRect&, float strokeWi dthForHairlinePadding = 0); 82 const FloatRect& localPaintInvalidationRect, LayoutRect&, float strokeWi dthForHairlinePadding = 0);
83 static void mapLocalToAncestor(const LayoutObject*, const LayoutBoxModelObje ct* ancestor, TransformState&, bool* wasFixed = nullptr, const PaintInvalidation State* = nullptr); 83 static void mapLocalToAncestor(const LayoutObject*, const LayoutBoxModelObje ct* ancestor, TransformState&, bool* wasFixed = nullptr, const PaintInvalidation State* = nullptr);
84 static void mapAncestorToLocal(const LayoutObject&, const LayoutBoxModelObje ct* ancestor, TransformState&);
84 static const LayoutObject* pushMappingToContainer(const LayoutObject*, const LayoutBoxModelObject* ancestorToStopAt, LayoutGeometryMap&); 85 static const LayoutObject* pushMappingToContainer(const LayoutObject*, const LayoutBoxModelObject* ancestorToStopAt, LayoutGeometryMap&);
85 86
86 // Shared between SVG layoutObjects and resources. 87 // Shared between SVG layoutObjects and resources.
87 static void applyStrokeStyleToStrokeData(StrokeData&, const ComputedStyle&, const LayoutObject&, float dashScaleFactor); 88 static void applyStrokeStyleToStrokeData(StrokeData&, const ComputedStyle&, const LayoutObject&, float dashScaleFactor);
88 89
89 static DashArray resolveSVGDashArray(const SVGDashArray&, const ComputedStyl e&, const SVGLengthContext&); 90 static DashArray resolveSVGDashArray(const SVGDashArray&, const ComputedStyl e&, const SVGLengthContext&);
90 91
91 // Determines if any ancestor's transform has changed. 92 // Determines if any ancestor's transform has changed.
92 static bool transformToRootChanged(LayoutObject*); 93 static bool transformToRootChanged(LayoutObject*);
93 94
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 return true; 137 return true;
137 if (child->hasNonIsolatedBlendingDescendants() && !willIsolateBlendingDe scendantsForObject(child)) 138 if (child->hasNonIsolatedBlendingDescendants() && !willIsolateBlendingDe scendantsForObject(child))
138 return true; 139 return true;
139 } 140 }
140 return false; 141 return false;
141 } 142 }
142 143
143 } // namespace blink 144 } // namespace blink
144 145
145 #endif // SVGLayoutSupport_h 146 #endif // SVGLayoutSupport_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698