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

Unified Diff: printing/metafile.cc

Issue 694213002: Remove calls to deprecated SkPDFDevice and SkPDFDocuemnt. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments from Vitaly Created 6 years, 1 month 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
Index: printing/metafile.cc
diff --git a/printing/metafile.cc b/printing/metafile.cc
index ece61dfa857ed87295961f9109ef168bcf2f4f3f..307ee5bf66ba96a662134893e864d2ae6793720b 100644
--- a/printing/metafile.cc
+++ b/printing/metafile.cc
@@ -23,6 +23,15 @@ Metafile::Metafile() {
Metafile::~Metafile() {
}
+skia::RefPtr<skia::VectorCanvas> Metafile::GetVectorCanvasForNewPage(
+ const gfx::Size& page_size, const gfx::Rect& content_area,
+ const float& scale_factor) {
+ SkBaseDevice* device =
+ this->StartPageForVectorCanvas(page_size, content_area, scale_factor);
Vitaly Buka (NO REVIEWS) 2014/11/04 19:23:55 don't need this->
+ if (!device) return skia::RefPtr<skia::VectorCanvas>(/*NULL*/);
+ return skia::AdoptRef(new skia::VectorCanvas(device));
+}
+
bool Metafile::GetDataAsVector(std::vector<char>* buffer) const {
buffer->resize(GetDataSize());
if (buffer->empty())

Powered by Google App Engine
This is Rietveld 408576698