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_dom_CSSLayerStatementRule_h
8 #define mozilla_dom_CSSLayerStatementRule_h
10 #include "mozilla/css/Rule.h"
11 #include "mozilla/ServoBindingTypes.h"
13 namespace mozilla::dom
{
15 class CSSLayerStatementRule final
: public css::Rule
{
17 CSSLayerStatementRule(RefPtr
<StyleLayerStatementRule
> aRawRule
,
18 StyleSheet
* aSheet
, css::Rule
* aParentRule
,
19 uint32_t aLine
, uint32_t aColumn
);
21 NS_DECL_ISUPPORTS_INHERITED
23 bool IsCCLeaf() const final
{ return css::Rule::IsCCLeaf(); }
26 void List(FILE* out
= stdout
, int32_t aIndent
= 0) const final
;
29 StyleLayerStatementRule
* Raw() const { return mRawRule
; }
30 void SetRawAfterClone(RefPtr
<StyleLayerStatementRule
>);
33 StyleCssRuleType
Type() const final
;
34 void GetCssText(nsACString
& aCssText
) const final
;
36 void GetNameList(nsTArray
<nsCString
>&) const;
38 size_t SizeOfIncludingThis(MallocSizeOf
) const override
;
39 JSObject
* WrapObject(JSContext
*, JS::Handle
<JSObject
*>) override
;
42 ~CSSLayerStatementRule() = default;
44 RefPtr
<StyleLayerStatementRule
> mRawRule
;
47 } // namespace mozilla::dom
49 #endif // mozilla_dom_CSSLayerStatementRule_h