no bug - Bumping Firefox l10n changesets r=release a=l10n-bump DONTBUILD CLOSED TREE
[gecko.git] / gfx / thebes / PrintTargetRecording.h
blobdccf35e615685a89f0300f742d9451f69898ab72
1 /* -*- Mode: C++; tab-width: 20; indent-tabs-mode: nil; c-basic-offset: 2 -*-
2 * This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 #ifndef MOZILLA_GFX_PRINTTARGETRECORDING_H
7 #define MOZILLA_GFX_PRINTTARGETRECORDING_H
9 #include "PrintTarget.h"
11 namespace mozilla {
12 namespace gfx {
14 /**
15 * Recording printing target.
17 * This exists for use on e10s's content process in order to record print
18 * output, send it over to the parent process, and replay it on a DrawTarget
19 * there for printing.
21 class PrintTargetRecording final : public PrintTarget {
22 public:
23 static already_AddRefed<PrintTargetRecording> CreateOrNull(
24 const IntSize& aSize);
26 already_AddRefed<DrawTarget> MakeDrawTarget(
27 const IntSize& aSize, DrawEventRecorder* aRecorder = nullptr) override;
29 private:
30 PrintTargetRecording(cairo_surface_t* aCairoSurface, const IntSize& aSize);
32 already_AddRefed<DrawTarget> CreateWrapAndRecordDrawTarget(
33 DrawEventRecorder* aRecorder, DrawTarget* aDrawTarget);
36 } // namespace gfx
37 } // namespace mozilla
39 #endif /* MOZILLA_GFX_PRINTTARGETRECORDING_H */