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

Unified Diff: src/utils/SkLua.cpp

Issue 1936283003: documentation: SkDocument::MakePDF() (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2016-05-02 (Monday) 17:27:37 EDT Created 4 years, 8 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 | « site/user/sample/pdf.md ('k') | tools/fiddle/fiddle_main.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/utils/SkLua.cpp
diff --git a/src/utils/SkLua.cpp b/src/utils/SkLua.cpp
index 9369a6bd9db4ed9425e32d5eb5a205c787fb6603..886f3d4ffd89bb4463edde1fb2df7d29fc21307c 100644
--- a/src/utils/SkLua.cpp
+++ b/src/utils/SkLua.cpp
@@ -1950,12 +1950,12 @@ static int lsk_newDocumentPDF(lua_State* L) {
file = lua_tolstring(L, 1, nullptr);
}
- SkDocument* doc = SkDocument::CreatePDF(file);
+ sk_sp<SkDocument> doc = SkDocument::MakePDF(file);
if (nullptr == doc) {
// do I need to push a nil on the stack and return 1?
return 0;
} else {
- push_ref(L, doc)->unref();
+ push_ref(L, std::move(doc));
return 1;
}
}
« no previous file with comments | « site/user/sample/pdf.md ('k') | tools/fiddle/fiddle_main.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698