OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006 Alexander Kellett <lypanov@kde.org> | 2 * Copyright (C) 2006 Alexander Kellett <lypanov@kde.org> |
3 * Copyright (C) 2006 Apple Computer, Inc. | 3 * Copyright (C) 2006 Apple Computer, Inc. |
4 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> | 4 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> |
5 * Copyright (C) 2007, 2008, 2009 Rob Buis <buis@kde.org> | 5 * Copyright (C) 2007, 2008, 2009 Rob Buis <buis@kde.org> |
6 * Copyright (C) 2009 Google, Inc. | 6 * Copyright (C) 2009 Google, Inc. |
7 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> | 7 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> |
8 * Copyright (C) 2010 Patrick Gansterer <paroga@paroga.com> | 8 * Copyright (C) 2010 Patrick Gansterer <paroga@paroga.com> |
9 * | 9 * |
10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 { | 65 { |
66 FloatRect oldBoundaries = m_objectBoundingBox; | 66 FloatRect oldBoundaries = m_objectBoundingBox; |
67 | 67 |
68 SVGLengthContext lengthContext(element()); | 68 SVGLengthContext lengthContext(element()); |
69 m_objectBoundingBox = FloatRect( | 69 m_objectBoundingBox = FloatRect( |
70 lengthContext.valueForLength(styleRef().svgStyle().x(), styleRef(), SVGL
engthMode::Width), | 70 lengthContext.valueForLength(styleRef().svgStyle().x(), styleRef(), SVGL
engthMode::Width), |
71 lengthContext.valueForLength(styleRef().svgStyle().y(), styleRef(), SVGL
engthMode::Height), | 71 lengthContext.valueForLength(styleRef().svgStyle().y(), styleRef(), SVGL
engthMode::Height), |
72 lengthContext.valueForLength(styleRef().width(), styleRef(), SVGLengthMo
de::Width), | 72 lengthContext.valueForLength(styleRef().width(), styleRef(), SVGLengthMo
de::Width), |
73 lengthContext.valueForLength(styleRef().height(), styleRef(), SVGLengthM
ode::Height)); | 73 lengthContext.valueForLength(styleRef().height(), styleRef(), SVGLengthM
ode::Height)); |
74 m_needsBoundariesUpdate |= oldBoundaries != m_objectBoundingBox; | 74 m_needsBoundariesUpdate |= oldBoundaries != m_objectBoundingBox; |
75 if (element()) | |
76 element()->setNeedsResizeObserverUpdate(); | |
77 } | 75 } |
78 | 76 |
79 void LayoutSVGImage::layout() | 77 void LayoutSVGImage::layout() |
80 { | 78 { |
81 ASSERT(needsLayout()); | 79 ASSERT(needsLayout()); |
82 LayoutAnalyzer::Scope analyzer(*this); | 80 LayoutAnalyzer::Scope analyzer(*this); |
83 | 81 |
84 // Invalidate all resources of this client if our layout changed. | 82 // Invalidate all resources of this client if our layout changed. |
85 if (everHadLayout() && selfNeedsLayout()) | 83 if (everHadLayout() && selfNeedsLayout()) |
86 SVGResourcesCache::clientLayoutChanged(this); | 84 SVGResourcesCache::clientLayoutChanged(this); |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
151 setShouldDoFullPaintInvalidation(); | 149 setShouldDoFullPaintInvalidation(); |
152 } | 150 } |
153 | 151 |
154 void LayoutSVGImage::addOutlineRects(Vector<LayoutRect>& rects, const LayoutPoin
t&, IncludeBlockVisualOverflowOrNot) const | 152 void LayoutSVGImage::addOutlineRects(Vector<LayoutRect>& rects, const LayoutPoin
t&, IncludeBlockVisualOverflowOrNot) const |
155 { | 153 { |
156 // this is called from paint() after the localTransform has already been app
lied | 154 // this is called from paint() after the localTransform has already been app
lied |
157 rects.append(LayoutRect(paintInvalidationRectInLocalSVGCoordinates())); | 155 rects.append(LayoutRect(paintInvalidationRectInLocalSVGCoordinates())); |
158 } | 156 } |
159 | 157 |
160 } // namespace blink | 158 } // namespace blink |
OLD | NEW |