| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "platform/graphics/paint/SkPictureBuilder.h" | 5 #include "platform/graphics/paint/SkPictureBuilder.h" |
| 6 | 6 |
| 7 #include "platform/geometry/FloatRect.h" | 7 #include "platform/geometry/FloatRect.h" |
| 8 #include "platform/graphics/GraphicsContext.h" | 8 #include "platform/graphics/GraphicsContext.h" |
| 9 #include "platform/graphics/paint/PaintController.h" | 9 #include "platform/graphics/paint/PaintController.h" |
| 10 #include "wtf/PtrUtil.h" | 10 #include "wtf/PtrUtil.h" |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 new GraphicsContext(*m_paintController, disabledMode, metaData)); | 30 new GraphicsContext(*m_paintController, disabledMode, metaData)); |
| 31 | 31 |
| 32 if (containingContext) { | 32 if (containingContext) { |
| 33 m_context->setDeviceScaleFactor(containingContext->deviceScaleFactor()); | 33 m_context->setDeviceScaleFactor(containingContext->deviceScaleFactor()); |
| 34 m_context->setPrinting(containingContext->printing()); | 34 m_context->setPrinting(containingContext->printing()); |
| 35 } | 35 } |
| 36 } | 36 } |
| 37 | 37 |
| 38 SkPictureBuilder::~SkPictureBuilder() {} | 38 SkPictureBuilder::~SkPictureBuilder() {} |
| 39 | 39 |
| 40 sk_sp<SkPicture> SkPictureBuilder::endRecording() { | 40 sk_sp<CdlPicture> SkPictureBuilder::endRecording() { |
| 41 m_context->beginRecording(m_bounds); | 41 m_context->beginRecording(m_bounds); |
| 42 m_paintController->commitNewDisplayItems(); | 42 m_paintController->commitNewDisplayItems(); |
| 43 m_paintController->paintArtifact().replay(*m_context); | 43 m_paintController->paintArtifact().replay(*m_context); |
| 44 return m_context->endRecording(); | 44 return m_context->endRecording(); |
| 45 } | 45 } |
| 46 | 46 |
| 47 } // namespace blink | 47 } // namespace blink |
| OLD | NEW |