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"
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
21 class PrintTargetRecording final
: public PrintTarget
{
23 static already_AddRefed
<PrintTargetRecording
> CreateOrNull(
24 const IntSize
& aSize
);
26 already_AddRefed
<DrawTarget
> MakeDrawTarget(
27 const IntSize
& aSize
, DrawEventRecorder
* aRecorder
= nullptr) override
;
30 PrintTargetRecording(cairo_surface_t
* aCairoSurface
, const IntSize
& aSize
);
32 already_AddRefed
<DrawTarget
> CreateWrapAndRecordDrawTarget(
33 DrawEventRecorder
* aRecorder
, DrawTarget
* aDrawTarget
);
37 } // namespace mozilla
39 #endif /* MOZILLA_GFX_PRINTTARGETRECORDING_H */