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

Unified Diff: src/pdf/SkPDFShader.cpp

Issue 1809733002: detach -> release (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: (C) Created 4 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/pdf/SkPDFFont.cpp ('k') | src/pdf/SkPDFStream.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/pdf/SkPDFShader.cpp
diff --git a/src/pdf/SkPDFShader.cpp b/src/pdf/SkPDFShader.cpp
index 2ae3217585856b8dd8cec27da35bf68880a71141..f5e5b1e439186517275f219032579a0159ade491 100644
--- a/src/pdf/SkPDFShader.cpp
+++ b/src/pdf/SkPDFShader.cpp
@@ -622,7 +622,7 @@ SkPDFAlphaFunctionShader* SkPDFAlphaFunctionShader::Create(
auto alphaGs = create_smask_graphic_state(canon, dpi, state);
SkPDFAlphaFunctionShader* alphaFunctionShader =
- new SkPDFAlphaFunctionShader(autoState->detach());
+ new SkPDFAlphaFunctionShader(autoState->release());
auto resourceDict =
get_gradient_resource_dict(colorShader.get(), alphaGs.get());
@@ -809,7 +809,7 @@ SkPDFFunctionShader* SkPDFFunctionShader::Create(
pdfShader->insertObjRef("Function", std::move(function));
sk_sp<SkPDFFunctionShader> pdfFunctionShader(
- new SkPDFFunctionShader(autoState->detach()));
+ new SkPDFFunctionShader(autoState->release()));
pdfFunctionShader->insertInt("PatternType", 2);
pdfFunctionShader->insertObject("Matrix",
SkPDFUtils::MatrixToArray(finalMatrix));
@@ -1021,7 +1021,7 @@ SkPDFImageShader* SkPDFImageShader::Create(
// Put the canvas into the pattern stream (fContent).
auto content = patternDevice->content();
- SkPDFImageShader* imageShader = new SkPDFImageShader(autoState->detach());
+ SkPDFImageShader* imageShader = new SkPDFImageShader(autoState->release());
imageShader->setData(content.get());
auto resourceDict = patternDevice->makeResourceDict();
« no previous file with comments | « src/pdf/SkPDFFont.cpp ('k') | src/pdf/SkPDFStream.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698