OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/CanvasSurfaceLayerBridge.h" | 5 #include "platform/graphics/CanvasSurfaceLayerBridge.h" |
6 | 6 |
7 #include "cc/surfaces/surface_id.h" | 7 #include "cc/surfaces/surface_id.h" |
8 #include "cc/surfaces/surface_sequence.h" | 8 #include "cc/surfaces/surface_sequence.h" |
9 #include "mojo/public/cpp/bindings/binding.h" | 9 #include "mojo/public/cpp/bindings/binding.h" |
10 #include "mojo/public/cpp/bindings/interface_request.h" | 10 #include "mojo/public/cpp/bindings/interface_request.h" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 } | 63 } |
64 | 64 |
65 void MockOffscreenCanvasSurface::GetSurfaceId(GetSurfaceIdCallback callback) { | 65 void MockOffscreenCanvasSurface::GetSurfaceId(GetSurfaceIdCallback callback) { |
66 std::move(callback).Run( | 66 std::move(callback).Run( |
67 cc::SurfaceId(cc::FrameSinkId(10, 11), | 67 cc::SurfaceId(cc::FrameSinkId(10, 11), |
68 cc::LocalFrameId(15, base::UnguessableToken::Create()))); | 68 cc::LocalFrameId(15, base::UnguessableToken::Create()))); |
69 } | 69 } |
70 | 70 |
71 void CanvasSurfaceLayerBridgeTest::SetUp() { | 71 void CanvasSurfaceLayerBridgeTest::SetUp() { |
72 m_surfaceLayerBridge = | 72 m_surfaceLayerBridge = |
73 wrapUnique(new CanvasSurfaceLayerBridge(m_service.GetProxy())); | 73 WTF::wrapUnique(new CanvasSurfaceLayerBridge(m_service.GetProxy())); |
74 } | 74 } |
75 | 75 |
76 TEST_F(CanvasSurfaceLayerBridgeTest, SurfaceLayerCreation) { | 76 TEST_F(CanvasSurfaceLayerBridgeTest, SurfaceLayerCreation) { |
77 bool success = this->surfaceLayerBridge()->createSurfaceLayer(50, 50); | 77 bool success = this->surfaceLayerBridge()->createSurfaceLayer(50, 50); |
78 EXPECT_TRUE(success); | 78 EXPECT_TRUE(success); |
79 } | 79 } |
80 | 80 |
81 } // namespace blink | 81 } // namespace blink |
OLD | NEW |