Move prepareForExternalIO implementation from GrContext to GrDrawingManager
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2324473002
Review-Url: https://codereview.chromium.org/2324473002
diff --git a/src/gpu/GrContext.cpp b/src/gpu/GrContext.cpp
index 357f58e..47fb323 100644
--- a/src/gpu/GrContext.cpp
+++ b/src/gpu/GrContext.cpp
@@ -518,13 +518,7 @@
RETURN_IF_ABANDONED
SkASSERT(surface);
ASSERT_OWNED_RESOURCE(surface);
- if (surface->surfacePriv().hasPendingIO()) {
- this->flush();
- }
- GrRenderTarget* rt = surface->asRenderTarget();
- if (fGpu && rt) {
- fGpu->resolveRenderTarget(rt);
- }
+ fDrawingManager->prepareSurfaceForExternalIO(surface);
}
bool GrContext::copySurface(GrSurface* dst, GrSurface* src, const SkIRect& srcRect,