Index: gm/rectangletexture.cpp |
diff --git a/gm/rectangletexture.cpp b/gm/rectangletexture.cpp |
index 47390e2e1911e496983cc311e059771f570211c6..099048754ca52716e2fcae9e990a4b4587e6cea7 100644 |
--- a/gm/rectangletexture.cpp |
+++ b/gm/rectangletexture.cpp |
@@ -119,9 +119,8 @@ protected: |
} |
void onDraw(SkCanvas* canvas) override { |
- GrRenderTarget* rt = canvas->internal_private_accessTopLayerRenderTarget(); |
- GrContext* context; |
- if (!rt || !(context = rt->getContext())) { |
+ GrContext *context = canvas->getGrContext(); |
+ if (!context) { |
skiagm::GM::DrawGpuOnlyMessage(canvas); |
return; |
} |