/work/obj-fuzz/dist/include/mozilla/dom/SVGFEPointLightElement.h
Line | Count | Source (jump to first uncovered line) |
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/. */ |
6 | | |
7 | | #ifndef mozilla_dom_SVGFEPointLightElement_h |
8 | | #define mozilla_dom_SVGFEPointLightElement_h |
9 | | |
10 | | #include "nsSVGFilters.h" |
11 | | #include "nsSVGNumber2.h" |
12 | | |
13 | | nsresult NS_NewSVGFEPointLightElement(nsIContent **aResult, |
14 | | already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo); |
15 | | |
16 | | namespace mozilla { |
17 | | namespace dom { |
18 | | |
19 | | typedef SVGFELightElement SVGFEPointLightElementBase; |
20 | | |
21 | | class SVGFEPointLightElement : public SVGFEPointLightElementBase |
22 | | { |
23 | | friend nsresult (::NS_NewSVGFEPointLightElement(nsIContent **aResult, |
24 | | already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)); |
25 | | protected: |
26 | | explicit SVGFEPointLightElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo) |
27 | | : SVGFEPointLightElementBase(std::move(aNodeInfo)) |
28 | 0 | { |
29 | 0 | } |
30 | | virtual JSObject* WrapNode(JSContext *cx, JS::Handle<JSObject*> aGivenProto) override; |
31 | | |
32 | | public: |
33 | | virtual mozilla::gfx::LightType ComputeLightAttributes(nsSVGFilterInstance* aInstance, |
34 | | nsTArray<float>& aFloatAttributes) override; |
35 | | virtual bool AttributeAffectsRendering( |
36 | | int32_t aNameSpaceID, nsAtom* aAttribute) const override; |
37 | | |
38 | | virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override; |
39 | | |
40 | | // WebIDL |
41 | | already_AddRefed<SVGAnimatedNumber> X(); |
42 | | already_AddRefed<SVGAnimatedNumber> Y(); |
43 | | already_AddRefed<SVGAnimatedNumber> Z(); |
44 | | |
45 | | protected: |
46 | | virtual NumberAttributesInfo GetNumberInfo() override; |
47 | | |
48 | | enum { ATTR_X, ATTR_Y, ATTR_Z }; |
49 | | nsSVGNumber2 mNumberAttributes[3]; |
50 | | static NumberInfo sNumberInfo[3]; |
51 | | }; |
52 | | |
53 | | } // namespace dom |
54 | | } // namespace mozilla |
55 | | |
56 | | #endif // mozilla_dom_SVGFEPointLightElement_h |