Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Side by Side Diff: src/gpu/GrContext.cpp

Issue 1156103006: Unblock DEPS roll by remove SkAutoTUnref from GrDrawContext (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « include/gpu/GrDrawContext.h ('k') | src/gpu/GrDrawContext.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2011 Google Inc. 3 * Copyright 2011 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "GrContext.h" 9 #include "GrContext.h"
10 10
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 fDrawContext = SkNEW_ARGS(GrDrawContext, (context, fDrawTarget)); 71 fDrawContext = SkNEW_ARGS(GrDrawContext, (context, fDrawTarget));
72 } 72 }
73 73
74 GrContext::DrawingMgr::~DrawingMgr() { 74 GrContext::DrawingMgr::~DrawingMgr() {
75 SkSafeUnref(fDrawTarget); 75 SkSafeUnref(fDrawTarget);
76 SkSafeUnref(fDrawContext); 76 SkSafeUnref(fDrawContext);
77 } 77 }
78 78
79 void GrContext::DrawingMgr::abandon() { 79 void GrContext::DrawingMgr::abandon() {
80 SkSafeSetNull(fDrawTarget); 80 SkSafeSetNull(fDrawTarget);
81 fDrawContext->fDrawTarget.reset(NULL); 81 SkSafeSetNull(fDrawContext->fDrawTarget);
82 SkSafeSetNull(fDrawContext); 82 SkSafeSetNull(fDrawContext);
83 } 83 }
84 84
85 void GrContext::DrawingMgr::purgeResources() { 85 void GrContext::DrawingMgr::purgeResources() {
86 if (fDrawTarget) { 86 if (fDrawTarget) {
87 fDrawTarget->purgeResources(); 87 fDrawTarget->purgeResources();
88 } 88 }
89 } 89 }
90 90
91 void GrContext::DrawingMgr::reset() { 91 void GrContext::DrawingMgr::reset() {
(...skipping 678 matching lines...) Expand 10 before | Expand all | Expand 10 after
770 ////////////////////////////////////////////////////////////////////////////// 770 //////////////////////////////////////////////////////////////////////////////
771 771
772 void GrContext::addGpuTraceMarker(const GrGpuTraceMarker* marker) { 772 void GrContext::addGpuTraceMarker(const GrGpuTraceMarker* marker) {
773 fGpu->addGpuTraceMarker(marker); 773 fGpu->addGpuTraceMarker(marker);
774 } 774 }
775 775
776 void GrContext::removeGpuTraceMarker(const GrGpuTraceMarker* marker) { 776 void GrContext::removeGpuTraceMarker(const GrGpuTraceMarker* marker) {
777 fGpu->removeGpuTraceMarker(marker); 777 fGpu->removeGpuTraceMarker(marker);
778 } 778 }
779 779
OLDNEW
« no previous file with comments | « include/gpu/GrDrawContext.h ('k') | src/gpu/GrDrawContext.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698