1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef MOZILLA_GFX_DRAWCOMMAND_H_
8 #define MOZILLA_GFX_DRAWCOMMAND_H_
16 #include "FilterNodeCapture.h"
22 class CaptureCommandList
;
24 enum class CommandType
: int8_t {
27 DRAWSURFACEWITHSHADOW
,
54 virtual ~DrawingCommand() {}
56 virtual void ExecuteOnDT(DrawTarget
* aDT
, const Matrix
* aTransform
= nullptr) const = 0;
57 virtual bool GetAffectedRect(Rect
& aDeviceRect
, const Matrix
& aTransform
) const { return false; }
58 virtual void CloneInto(CaptureCommandList
* aList
) = 0;
59 virtual void Log(TreeLog
& aLog
) const = 0;
61 CommandType
GetType() { return mType
; }
64 explicit DrawingCommand(CommandType aType
)
74 } // namespace mozilla
76 #endif /* MOZILLA_GFX_DRAWCOMMAND_H_ */