| Index: Source/core/platform/graphics/Canvas2DLayerBridgeTest.cpp
|
| diff --git a/Source/core/platform/graphics/Canvas2DLayerBridgeTest.cpp b/Source/core/platform/graphics/Canvas2DLayerBridgeTest.cpp
|
| index 391808afeb61672d6717a93fa7e8359a59dedd9c..3f60d4567a4252907fb5af06639a692d533c7efe 100644
|
| --- a/Source/core/platform/graphics/Canvas2DLayerBridgeTest.cpp
|
| +++ b/Source/core/platform/graphics/Canvas2DLayerBridgeTest.cpp
|
| @@ -55,12 +55,12 @@ public:
|
|
|
| class FakeCanvas2DLayerBridge : public Canvas2DLayerBridge {
|
| public:
|
| - static PassRefPtr<Canvas2DLayerBridge> create(PassRefPtr<GraphicsContext3D> context, PassRefPtr<SkDeferredCanvas> canvas, OpacityMode opacityMode)
|
| + static PassRefPtr<Canvas2DLayerBridge> create(PassRefPtr<GraphicsContext3D> context, PassOwnPtr<SkDeferredCanvas> canvas, OpacityMode opacityMode)
|
| {
|
| return adoptRef(static_cast<Canvas2DLayerBridge*>(new FakeCanvas2DLayerBridge(context, canvas, opacityMode)));
|
| }
|
| protected:
|
| - FakeCanvas2DLayerBridge(PassRefPtr<GraphicsContext3D> context, PassRefPtr<SkDeferredCanvas> canvas, OpacityMode opacityMode) :
|
| + FakeCanvas2DLayerBridge(PassRefPtr<GraphicsContext3D> context, PassOwnPtr<SkDeferredCanvas> canvas, OpacityMode opacityMode) :
|
| Canvas2DLayerBridge(context, canvas, 0, opacityMode)
|
| { }
|
| };
|
| @@ -75,20 +75,21 @@ protected:
|
|
|
| MockCanvasContext& mainMock = *static_cast<MockCanvasContext*>(mainContext->webContext());
|
|
|
| - RefPtr<SkDeferredCanvas> canvas = adoptRef(SkDeferredCanvas::Create(SkSurface::NewRasterPMColor(300, 150)));
|
| + OwnPtr<SkDeferredCanvas> canvas = adoptPtr(SkDeferredCanvas::Create(SkSurface::NewRasterPMColor(300, 150)));
|
|
|
| ::testing::Mock::VerifyAndClearExpectations(&mainMock);
|
|
|
| - Canvas2DLayerBridgePtr bridge = FakeCanvas2DLayerBridge::create(mainContext.release(), canvas.release(), Canvas2DLayerBridge::NonOpaque);
|
| + RefPtr<Canvas2DLayerBridge> bridge = FakeCanvas2DLayerBridge::create(mainContext.release(), canvas.release(), NonOpaque);
|
|
|
| ::testing::Mock::VerifyAndClearExpectations(&mainMock);
|
|
|
| EXPECT_CALL(mainMock, flush());
|
| - unsigned textureId = bridge->backBufferTexture();
|
| + unsigned textureId = bridge->getBackingTexture();
|
| EXPECT_EQ(textureId, 0u);
|
|
|
| ::testing::Mock::VerifyAndClearExpectations(&mainMock);
|
|
|
| + bridge->destroy();
|
| bridge.clear();
|
|
|
| ::testing::Mock::VerifyAndClearExpectations(&mainMock);
|
|
|