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

Unified Diff: cc/paint/paint_canvas.h

Issue 2686033005: Move metafile printing code from platform canvas to PaintCanvas (Closed)
Patch Set: Fix missing build_config include Created 3 years, 10 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 | « no previous file | cc/paint/paint_canvas.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/paint/paint_canvas.h
diff --git a/cc/paint/paint_canvas.h b/cc/paint/paint_canvas.h
index 6df34439c315f69544fe83ae0d27c7be7815e456..649096cf8ea9b8c865b63408c1e3fe6470769f63 100644
--- a/cc/paint/paint_canvas.h
+++ b/cc/paint/paint_canvas.h
@@ -5,6 +5,7 @@
#ifndef CC_PAINT_PAINT_CANVAS_H_
#define CC_PAINT_PAINT_CANVAS_H_
+#include "build/build_config.h"
#include "cc/paint/paint_export.h"
#include "third_party/skia/include/core/SkCanvas.h"
#include "third_party/skia/include/utils/SkNWayCanvas.h"
@@ -23,9 +24,18 @@ class CC_PAINT_EXPORT PaintCanvasPassThrough : public SkNWayCanvas {
~PaintCanvasPassThrough() override;
};
+// TODO(enne): Move all these functions into PaintCanvas.
+
// PaintCanvas equivalent of skia::GetWritablePixels.
CC_PAINT_EXPORT bool ToPixmap(PaintCanvas* canvas, SkPixmap* output);
+// Following routines are used in print preview workflow to mark the
+// preview metafile.
+#if defined(OS_MACOSX)
+CC_PAINT_EXPORT void SetIsPreviewMetafile(PaintCanvas* canvas, bool is_preview);
+CC_PAINT_EXPORT bool IsPreviewMetafile(PaintCanvas* canvas);
+#endif
+
} // namespace cc
#endif // CC_PAINT_PAINT_CANVAS_H_
« no previous file with comments | « no previous file | cc/paint/paint_canvas.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698