| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2006 Nikolas Zimmermann <zimmermann@kde.org> |
| 3 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 3 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
| 4 * Copyright 2014 The Chromium Authors. All rights reserved. | 4 * Copyright 2014 The Chromium Authors. 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 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 tileTransform.scale(clientBoundingBox.width(), clientBoundingBox.hei
ght()); | 107 tileTransform.scale(clientBoundingBox.width(), clientBoundingBox.hei
ght()); |
| 108 } | 108 } |
| 109 | 109 |
| 110 OwnPtr<PatternData> patternData = adoptPtr(new PatternData); | 110 OwnPtr<PatternData> patternData = adoptPtr(new PatternData); |
| 111 patternData->pattern = Pattern::createPicturePattern(asPicture(tileBounds, t
ileTransform)); | 111 patternData->pattern = Pattern::createPicturePattern(asPicture(tileBounds, t
ileTransform)); |
| 112 | 112 |
| 113 // Compute pattern space transformation. | 113 // Compute pattern space transformation. |
| 114 patternData->transform.translate(tileBounds.x(), tileBounds.y()); | 114 patternData->transform.translate(tileBounds.x(), tileBounds.y()); |
| 115 patternData->transform.preMultiply(attributes.patternTransform()); | 115 patternData->transform.preMultiply(attributes.patternTransform()); |
| 116 | 116 |
| 117 return patternData.release(); | 117 return patternData; |
| 118 } | 118 } |
| 119 | 119 |
| 120 SVGPaintServer LayoutSVGResourcePattern::preparePaintServer(const LayoutObject&
object) | 120 SVGPaintServer LayoutSVGResourcePattern::preparePaintServer(const LayoutObject&
object) |
| 121 { | 121 { |
| 122 clearInvalidationMask(); | 122 clearInvalidationMask(); |
| 123 | 123 |
| 124 SVGPatternElement* patternElement = toSVGPatternElement(element()); | 124 SVGPatternElement* patternElement = toSVGPatternElement(element()); |
| 125 if (!patternElement) | 125 if (!patternElement) |
| 126 return SVGPaintServer::invalid(); | 126 return SVGPaintServer::invalid(); |
| 127 | 127 |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 { | 193 { |
| 194 TransformRecorder transformRecorder(pictureBuilder.context(), *patternLa
youtObject, tileTransform); | 194 TransformRecorder transformRecorder(pictureBuilder.context(), *patternLa
youtObject, tileTransform); |
| 195 for (LayoutObject* child = patternLayoutObject->firstChild(); child; chi
ld = child->nextSibling()) | 195 for (LayoutObject* child = patternLayoutObject->firstChild(); child; chi
ld = child->nextSibling()) |
| 196 SVGPaintContext::paintSubtree(pictureBuilder.context(), child); | 196 SVGPaintContext::paintSubtree(pictureBuilder.context(), child); |
| 197 } | 197 } |
| 198 | 198 |
| 199 return pictureBuilder.endRecording(); | 199 return pictureBuilder.endRecording(); |
| 200 } | 200 } |
| 201 | 201 |
| 202 } // namespace blink | 202 } // namespace blink |
| OLD | NEW |