OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2006 Apple Computer, Inc. | 2 * Copyright (C) 2006 Apple Computer, Inc. |
3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> | 3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> |
4 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 4 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
5 * | 5 * |
6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
10 * | 10 * |
(...skipping 18 matching lines...) Loading... | |
29 #include "core/layout/svg/SVGResourcesCache.h" | 29 #include "core/layout/svg/SVGResourcesCache.h" |
30 #include "core/svg/SVGElement.h" | 30 #include "core/svg/SVGElement.h" |
31 | 31 |
32 namespace blink { | 32 namespace blink { |
33 | 33 |
34 LayoutSVGBlock::LayoutSVGBlock(SVGElement* element) | 34 LayoutSVGBlock::LayoutSVGBlock(SVGElement* element) |
35 : LayoutBlockFlow(element) | 35 : LayoutBlockFlow(element) |
36 { | 36 { |
37 } | 37 } |
38 | 38 |
39 LayoutRect LayoutSVGBlock::visualOverflowRect() const | 39 LayoutRect LayoutSVGBlock::visualOverflowRect() const |
chrishtr
2015/06/03 22:12:53
Is this only ever used in BoxPainter when painting
fs
2015/06/04 09:13:31
No, AFAIK it's only used in BlockPainter (overflow
| |
40 { | 40 { |
41 LayoutRect borderRect = borderBoxRect(); | 41 LayoutRect borderRect = borderBoxRect(); |
42 | 42 if (style()->hasVisualOverflowingEffect()) |
43 if (const ShadowList* textShadow = style()->textShadow()) | 43 borderRect.expand(computeVisualEffectOverflowOutsets()); |
chrishtr
2015/06/02 15:51:05
LayoutBox computes visual overflow during layout.
| |
44 textShadow->adjustRectForShadow(borderRect); | |
45 | |
46 return borderRect; | 44 return borderRect; |
47 } | 45 } |
48 | 46 |
49 void LayoutSVGBlock::updateFromStyle() | 47 void LayoutSVGBlock::updateFromStyle() |
50 { | 48 { |
51 LayoutBlock::updateFromStyle(); | 49 LayoutBlock::updateFromStyle(); |
52 | 50 |
53 // LayoutSVGlock, used by Layout(SVGText|ForeignObject), is not allowed to c all setHasOverflowClip(true). | 51 // LayoutSVGlock, used by Layout(SVGText|ForeignObject), is not allowed to c all setHasOverflowClip(true). |
54 // LayoutBlock assumes a layer to be present when the overflow clip function ality is requested. Both | 52 // LayoutBlock assumes a layer to be present when the overflow clip function ality is requested. Both |
55 // Layout(SVGText|ForeignObject) return 'NoDeprecatedPaintLayer' on 'layerTy peRequired'. Fine for LayoutSVGText. | 53 // Layout(SVGText|ForeignObject) return 'NoDeprecatedPaintLayer' on 'layerTy peRequired'. Fine for LayoutSVGText. |
(...skipping 68 matching lines...) Loading... | |
124 void LayoutSVGBlock::invalidateTreeIfNeeded(PaintInvalidationState& paintInvalid ationState) | 122 void LayoutSVGBlock::invalidateTreeIfNeeded(PaintInvalidationState& paintInvalid ationState) |
125 { | 123 { |
126 if (!shouldCheckForPaintInvalidation(paintInvalidationState)) | 124 if (!shouldCheckForPaintInvalidation(paintInvalidationState)) |
127 return; | 125 return; |
128 | 126 |
129 ForceHorriblySlowRectMapping slowRectMapping(&paintInvalidationState); | 127 ForceHorriblySlowRectMapping slowRectMapping(&paintInvalidationState); |
130 LayoutBlockFlow::invalidateTreeIfNeeded(paintInvalidationState); | 128 LayoutBlockFlow::invalidateTreeIfNeeded(paintInvalidationState); |
131 } | 129 } |
132 | 130 |
133 } | 131 } |
OLD | NEW |