| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "webkit/plugins/ppapi/mock_platform_image_2d.h" | |
| 6 | |
| 7 #include "skia/ext/platform_canvas.h" | |
| 8 | |
| 9 namespace webkit { | |
| 10 namespace ppapi { | |
| 11 | |
| 12 MockPlatformImage2D::MockPlatformImage2D(int width, int height) | |
| 13 : width_(width), | |
| 14 height_(height) { | |
| 15 } | |
| 16 | |
| 17 MockPlatformImage2D::~MockPlatformImage2D() { | |
| 18 } | |
| 19 | |
| 20 skia::PlatformCanvas* MockPlatformImage2D::Map() { | |
| 21 return skia::CreatePlatformCanvas(width_, height_, true); | |
| 22 } | |
| 23 | |
| 24 intptr_t MockPlatformImage2D::GetSharedMemoryHandle(uint32* byte_count) const { | |
| 25 *byte_count = 0; | |
| 26 return 0; | |
| 27 } | |
| 28 | |
| 29 TransportDIB* MockPlatformImage2D::GetTransportDIB() const { | |
| 30 return NULL; | |
| 31 } | |
| 32 | |
| 33 } // namespace ppapi | |
| 34 } // namespace webkit | |
| OLD | NEW |