Move lastRenderTask into drawing manager

Bug: skia:10320
Change-Id: I5a25d8c0bf00b379a37c479e79d4ff16403e9dfe
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294339
Commit-Queue: Adlai Holler <adlai@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
diff --git a/src/gpu/GrOnFlushResourceProvider.cpp b/src/gpu/GrOnFlushResourceProvider.cpp
index 0ca9f13..93bf9db 100644
--- a/src/gpu/GrOnFlushResourceProvider.cpp
+++ b/src/gpu/GrOnFlushResourceProvider.cpp
@@ -52,12 +52,12 @@
     // Since we are bypassing normal DAG operation, we need to ensure the textureProxy's last render
     // task gets closed before making a texture resolve task. makeClosed is what will mark msaa and
     // mipmaps dirty.
-    if (GrRenderTask* renderTask = textureProxy->getLastRenderTask()) {
+    if (GrRenderTask* renderTask = fDrawingMgr->getLastRenderTask(textureProxy.get())) {
         renderTask->makeClosed(*this->caps());
     }
     auto task = static_cast<GrTextureResolveRenderTask*>(fDrawingMgr->fOnFlushRenderTasks.push_back(
             sk_make_sp<GrTextureResolveRenderTask>()).get());
-    task->addProxy(std::move(textureProxy), resolveFlags, *this->caps());
+    task->addProxy(fDrawingMgr, std::move(textureProxy), resolveFlags, *this->caps());
     task->makeClosed(*this->caps());
 }