| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006 Apple Computer, Inc. | 2 * Copyright (C) 2006 Apple Computer, Inc. |
| 3 * Copyright (C) 2009 Google, Inc. | 3 * Copyright (C) 2009 Google, Inc. |
| 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 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 77 } | 77 } |
| 78 | 78 |
| 79 void RenderSVGForeignObject::layout() | 79 void RenderSVGForeignObject::layout() |
| 80 { | 80 { |
| 81 ASSERT(needsLayout()); | 81 ASSERT(needsLayout()); |
| 82 | 82 |
| 83 SVGForeignObjectElement* foreign = toSVGForeignObjectElement(node()); | 83 SVGForeignObjectElement* foreign = toSVGForeignObjectElement(node()); |
| 84 | 84 |
| 85 bool updateCachedBoundariesInParents = false; | 85 bool updateCachedBoundariesInParents = false; |
| 86 if (m_needsTransformUpdate) { | 86 if (m_needsTransformUpdate) { |
| 87 m_localTransform = foreign->animatedLocalTransform(); | 87 m_localTransform = foreign->calculateAnimatedLocalTransform(); |
| 88 m_needsTransformUpdate = false; | 88 m_needsTransformUpdate = false; |
| 89 updateCachedBoundariesInParents = true; | 89 updateCachedBoundariesInParents = true; |
| 90 } | 90 } |
| 91 | 91 |
| 92 FloatRect oldViewport = m_viewport; | 92 FloatRect oldViewport = m_viewport; |
| 93 | 93 |
| 94 // Cache viewport boundaries | 94 // Cache viewport boundaries |
| 95 SVGLengthContext lengthContext(foreign); | 95 SVGLengthContext lengthContext(foreign); |
| 96 FloatPoint viewportLocation(foreign->x()->currentValue()->value(lengthContex
t), foreign->y()->currentValue()->value(lengthContext)); | 96 FloatPoint viewportLocation(foreign->x()->currentValue()->value(lengthContex
t), foreign->y()->currentValue()->value(lengthContext)); |
| 97 m_viewport = FloatRect(viewportLocation, FloatSize(foreign->width()->current
Value()->value(lengthContext), foreign->height()->currentValue()->value(lengthCo
ntext))); | 97 m_viewport = FloatRect(viewportLocation, FloatSize(foreign->width()->current
Value()->value(lengthContext), foreign->height()->currentValue()->value(lengthCo
ntext))); |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 143 return false; | 143 return false; |
| 144 | 144 |
| 145 // FOs establish a stacking context, so we need to hit-test all layers. | 145 // FOs establish a stacking context, so we need to hit-test all layers. |
| 146 HitTestLocation hitTestLocation(roundedLayoutPoint(localPoint)); | 146 HitTestLocation hitTestLocation(roundedLayoutPoint(localPoint)); |
| 147 return RenderBlock::nodeAtPoint(request, result, hitTestLocation, LayoutPoin
t(), HitTestForeground) | 147 return RenderBlock::nodeAtPoint(request, result, hitTestLocation, LayoutPoin
t(), HitTestForeground) |
| 148 || RenderBlock::nodeAtPoint(request, result, hitTestLocation, LayoutPoin
t(), HitTestFloat) | 148 || RenderBlock::nodeAtPoint(request, result, hitTestLocation, LayoutPoin
t(), HitTestFloat) |
| 149 || RenderBlock::nodeAtPoint(request, result, hitTestLocation, LayoutPoin
t(), HitTestChildBlockBackgrounds); | 149 || RenderBlock::nodeAtPoint(request, result, hitTestLocation, LayoutPoin
t(), HitTestChildBlockBackgrounds); |
| 150 } | 150 } |
| 151 | 151 |
| 152 } | 152 } |
| OLD | NEW |